I am building a screen to display a collection data and I need to have a pagination with only 10 records being displayed on a page at a time.
Is there any option to get the total records count - I am searching a collection with some criteria using listcallback api.
I can build the pagination using the "nb" and the "first" parameters in the option but not sure how to get the total records.
Any help is much appreciated.
Thank you!!
Regards,
Siva
Regards,
Siva
Thank you.
Regards,
Siva
var options = {}; options.fields = ["firstname","lastname"];// retrieve objects with only firstname and lastname fields. Default is [] options.mode = "TEST"; // retrieve data from the TEST or the LIVE collection. Default is current mode options.nb = 5; // max nb of items to list. Default is 100. Max is 1000. options.first = 2; // starting index to list objects. Default is 0 options.orderby = ["lastname","firstname"]; //order by lastname and firstname. Default is [] options.order = ["asc","desc"]; //must match orderby : order by lastname asc and firstname desc. Default is [] options.asynchronous = false; //if you need synchronous requests, must be set as false. Default is true
You will find all needed information into this user guide page : http://docs.runmyprocess.com/Developer_Guide/Collection/Collection_JS_Freemarker
Best regards.
--
Dimitri MELCHIOR
To view this discussion on the web visit https://groups.google.com/a/runmyprocess.com/d/msgid/supportforum/ee4e1845-1843-4e44-9f92-cef88731a032%40runmyprocess.com.
Regards,
Siva
--
Fujitsu - RunMyProcess
---
You received this message because you are subscribed to the Google Groups "RunMyProcess Support Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email to supportforum...@runmyprocess.com.
To post to this group, send email to suppor...@runmyprocess.com.
Visit this group at http://groups.google.com/a/runmyprocess.com/group/supportforum/.
For more options, visit https://groups.google.com/a/runmyprocess.com/groups/opt_out.
Thanks for your response. I am using the option parameter to control the result data. But for me to build the pagination, I need to know the total number of records that would be returned by the search query. For example, if my query returns 700 records, then I have to build 70 pages with 10 records per page. The option parameter will be helpful to build all those pages, but for me to come up with the pagination screen with 70 pages, I need to know the total records count.
There is a ${count_objects(object-pattern, collection-name)} Freemarker API. But I am looking for an equivalent Javascript API.
Please let me know if I am not clear.
Thank You!
Regards,
Siva
--
Dimitri MELCHIOR
Regards,
Siva
--
Fujitsu - RunMyProcess
---
You received this message because you are subscribed to the Google Groups "RunMyProcess Support Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email to supportforum...@runmyprocess.com.
To post to this group, send email to suppor...@runmyprocess.com.
Visit this group at http://groups.google.com/a/runmyprocess.com/group/supportforum/.
To view this discussion on the web visit https://groups.google.com/a/runmyprocess.com/d/msgid/supportforum/bc2a8cfc-2c41-453a-bba2-86d4b87a33fa%40runmyprocess.com.