Nisa Khalid
Posts: 0
Joined: Tue May 05, 2015 1:36 pm

how to store total of user has been signup?

i have made registration for two user ,one for parents and one for kids
parents need to register first then parents have register for their kids, parents only allowed to register 3 kids only. means that one parents can add 3 children

i want to store the total of kid has been register by their parents and if the total more than 3 ,they cannot add/register another kids. i want to store the total and make validation? how can i do this? i'm still new with appery.io and i'm a student

Serhii Kulibaba
Posts: 150
Joined: Tue Aug 27, 2013 1:47 pm

how to store total of user has been signup?

Hello Nisa,

You can save amount of registered children in additional column:
https://devcenter.appery.io/documenta...

Nisa Khalid
Posts: 0
Joined: Tue May 05, 2015 1:36 pm

how to store total of user has been signup?

i have collection myKids in database? is it put in this collection?

Alena Prykhodko
Posts: 0
Joined: Tue Apr 09, 2013 7:36 am

how to store total of user has been signup?

Hello Nisa,

Yes. You can use the same collection.

Nisa Khalid
Posts: 0
Joined: Tue May 05, 2015 1:36 pm

how to store total of user has been signup?

okay, how can i get the value of registered user?

Yurii Orishchuk
Posts: 0
Joined: Fri Feb 14, 2014 8:20 am

how to store total of user has been signup?

Hi Nisa,

You need to use "count" request parameter for your "list/query" service.

More info here: https://devcenter.appery.io/documenta...

Here is a common steps to populate label with count rows in db, you can also use here "where" request parameter for narrow items:

  1. Open your list service.

  2. Add "where" and "count" request parameters. http://prntscr.com/51gys0/direct

  3. Navigate to "Test" tab and click "Test". You will get result of all item counts.

  4. Click "Import as response". http://prntscr.com/51gzdz/direct

  5. Navigate to "response" tab and check if you have parameters like on screen shot: http://prntscr.com/51h078/direct

  6. Add this service to the page.

  7. Open "Success" mapping for this service. And create link from "count" to label component you need. http://prntscr.com/51h23q/direct

  8. Now you need to invoke this service datasource by event you wish. For example on "page load" or "button click" etc...

    Regards.

Nisa Khalid
Posts: 0
Joined: Tue May 05, 2015 1:36 pm

how to store total of user has been signup?

thank you,this is very useful but i need to know
what if i don't want to display it?
for example the parents can register their kids after they has login,so i want to use the value from count is for if the user has register for their kids more than 3 times ( the kids register in another page)
i already follow the step and i found i dont have any label cause i don't want to display it

Return to “Issues”