Uploaded image for project: 'PUBLIC - Liferay Portal Community Edition'
  1. PUBLIC - Liferay Portal Community Edition
  2. LPS-91069

Pagination properties are not showing the right information

    Details

    • Type: Bug
    • Status: Closed
    • Resolution: Fixed
    • Affects Version/s: Master
    • Fix Version/s: Master
    • Component/s: Headless Delivery API
    • Labels:
      None
    • Fix Priority:
      4

      Description

      In any collection of the APIs, the information provided by these properties is not showing the correct info:

      "itemsPerPage": 1,
      "lastPageNumber": 1,
      "pageNumber": 2,
      "totalCount": 1

      • lastPageNumber is always showing "1" (even if there are several pages)
        -totalCount is showing the numbers of the elements in the current page, not the totalCount.
        In hypermedia, we had 2 parameters: count -> elements in a page. total -> elements in the collection. We could recover it and have pageCount and totalCount.

      Moreover, I'd suggest aligning page, pageSize parameters with properties pageNumber and itemsPerPage so they have the same values

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              brian.chan Brian Chan
              Reporter:
              pablo.agulla Pablo Agulla
              Participants of an Issue:
              Recent user:
              Tibor Lipusz
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:
                Days since last comment:
                1 year, 34 weeks, 3 days ago

                  Packages

                  Version Package
                  Master