force integers for appropriate values

non-nil per_page is always an integer, regardless of whether the
folio or page is ordinal or not.

current_page and explicitly assigned non-nil next_page on ordinal pages
are always integers; implicit non-nil next_page, previous_page, and
last_page are already calculated as integers.

Change-Id: Ifc9ee7f5d7c984abded07fa67fda3feea1222e1e
Merge branch 'master' into legacy

Change-Id: Ifee8e79051a51dbf5804843b4cb6a2a7d3f1e739
handle string page/per_page during AR pagination

when total_entries is not supplied and we're doing the count, don't die
on string values for page or per_page

Change-Id: Ib47895ec171df91e09c10f6cfbaf35b299ac104b