Open Oaphi opened 10 months ago
I'm not familiar with Rails' pagination functionality so I don't know how to completely fix this, but just in case it helps I believe the numbering of the edits can be calculated using information which already seems to be available:
@count
: the total number of editsper_page
: the number to show per page in the pagination@page
: the currently displayed pageIf you know the number of an item within the current page (from 1 to per_page), say number_in_page
, then the number to display (the edit number) can be calculated as:
@count - (number_in_page - 1) - (@page - 1) * per_page
The 1s are due to number_in_page
and @page
being 1-indexed rather than 0-indexed. They can be omitted if those variables are actually 0-indexed.
Closes #1229