Skip to content

Improve the JS pagination to handle the case when the `X-Total` and `X-Total-Pages` headers aren't present

What does this MR do?

This improves the JS pagination to handle the case when the X-Total and X-Total-Pages headers aren't present.

Screenshots

With the X-Total and X-Total-Pages present

Page Screenshot Notes
First and only page Screen_Shot_2019-02-28_at_11.04.18 No pagination.
First page Screen_Shot_2019-02-28_at_11.59.24 "Next", page numbers and "Last" are enabled. "Prev" is disabled. "First" isn't shown.
Second page Screen_Shot_2019-02-28_at_11.59.33 "First", "Prev", page numbers, "Next" and "Last" are enabled.
Last page Screen_Shot_2019-02-28_at_11.59.55 "First", "Prev" and page numbers are enabled. "Next" is disabled. "Last" isn't shown.

With the X-Total and X-Total-Pages missing

Page Screenshot Notes
First and only page Screen_Shot_2019-02-28_at_11.04.18 No pagination.
First page Screen_Shot_2019-02-28_at_12.00.21 "Next" is enabled. "Prev" is disabled. "First", page numbers and "Last" aren't shown.
Second page Screen_Shot_2019-02-28_at_12.00.28 "First", "Prev" and "Next" are enabled. Page numbers and "Last" aren't shown.
Last page Screen_Shot_2019-02-28_at_12.00.40 "First" and "Previous" are enabled. "Next" is disabled. Page numbers and "Last" aren't shown.

What are the relevant issue numbers?

Closes #57991 (closed).

Does this MR meet the acceptance criteria?

Edited by Rémy Coutable

Merge request reports