Page 1 of 2

dynamic list

Posted: Fri Aug 02, 2013 11:09 am
by Fabian Unruh

My dynamic list on base of a user selection is not working.

Here's what I do:

Page 1: A select box is displayed. Event: On value change I store a local storage variable (name: zipcodeuser value: 8142 (static for testing)), then i navigate to the next page.

on Page 2: i have another select box where i map the local variable to the Where clause with JS: return '{"ZIPCode": ' + value + '}' -- ZIPCode is the column name.

what am I doing wrong?

I also recognized, that the second page only loads when I make a selection for the second time. the first time it always reloads page 1.

thanks so much for your support.


dynamic list

Posted: Fri Aug 02, 2013 12:56 pm
by Maryna Brodina

Hello! What is the type of "ZIPCode" field in DB? Before codereturn '{"ZIPCode": ' + value + '}'/code do codealert('{"ZIPCode": ' + value + '}');/code this way you'll be able to see request you send on server.


dynamic list

Posted: Fri Aug 02, 2013 1:14 pm
by Fabian Unruh

woohooo it works...
its a string and i added " to the value JS

return '{"ZIPCode": ' + value + '}' -- return '{"ZIPCode": "' + value + '"}'

thanks!

leaves me with the problem that if i select an item in the list for the first time the second page loads but leads me back to the first page. after i select an item the second time the second page loads and stays. any idea?


dynamic list

Posted: Fri Aug 02, 2013 1:36 pm
by Maryna Brodina

What actions do you have on Show event on second page?


dynamic list

Posted: Fri Aug 02, 2013 1:50 pm
by Fabian Unruh

hi there... i just invoke the query service as an action on the second page.


dynamic list

Posted: Fri Aug 02, 2013 1:57 pm
by Fabian Unruh

maybe i'll do all the selection on one page and reload it after the user selects an option. maybe this affects UX in a positiv way...


dynamic list

Posted: Fri Aug 02, 2013 1:58 pm
by Maryna Brodina

Please give us public app link.


dynamic list

Posted: Fri Aug 02, 2013 3:16 pm
by Fabian Unruh

Hi there, i'm now doing it all on 1 page.
thanks for your support!


dynamic list

Posted: Fri Aug 02, 2013 3:36 pm
by Kateryna Grynko

Hi Fabian, please share your app with a href="mailto:support@appery.io" rel="nofollow"support@appery.io/a or tick "public" and give us the app test link.


dynamic list

Posted: Sun Sep 08, 2013 8:18 am
by Deon

Hi

I am having a problem with this as well. My list return is blank.

i did the following as suggested
alert('{"StoreType": ' + value + '}');
It returns the correct value I am looking for and the table contains many rows with that value however not displaying the records.