Fix pagination count

The number of records in the system is the number of document_ids, not the number of editions.

This makes the publishing tool show 3 pages of CMA cases instead of 7 pages.