The 'show more' pagination needs to be a bit more flexible

Bug #1979372 reported by Robert Lyon
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Mahara
Fix Released
Wishlist
Robert Lyon

Bug Description

Currently when fetching new data with the 'show more' button it will replace the content parent HTML element of the button with the new content.

This worked fine when the parent element was a <div> tag but fails if the parent HTML element of the button is something like a <TD> we end up replacing content of table rows into the table cell rather than replacing the table row.

Need an adjustment on the 'show more' pagination where we can specify the closest HTML tag to do the replace content step on.

To test:
As this change is just to make the 'show more' pagination more robust the testing will be making sure current places work correctly still.

So easiest test is to go to 'Pages and collection' page and have enough pages to cause the 'Show more' button to appear, say 14 page, and then clicking it appends more data to the page.

Robert Lyon (robertl-9)
Changed in mahara:
milestone: none → 22.10.0
importance: Undecided → Wishlist
status: New → In Progress
Revision history for this message
Mahara Bot (dev-mahara) wrote : A patch has been submitted for review
Doris Tam (doristam)
Changed in mahara:
assignee: nobody → Gold (gold.catalyst)
Doris Tam (doristam)
Changed in mahara:
assignee: Gold (gold.catalyst) → Robert Lyon (robertl-9)
Revision history for this message
Mahara Bot (dev-mahara) wrote : A change has been merged

Reviewed: https://reviews.mahara.org/c/mahara/+/12944
Committed: https://git.mahara.org/mahara/mahara/commit/3c0904ee6b3fc2c64e3a145e6ecadbc36fb3bbb8
Submitter: "Robert Lyon <email address hidden>"
Branch: main

commit 3c0904ee6b3fc2c64e3a145e6ecadbc36fb3bbb8
Author: Robert Lyon <email address hidden>
Date: Wed Jun 22 12:56:46 2022 +1200

Bug 1979372: Alter 'Show more' pagination

Allow the 'Show more' pagination to indicate what HTML container to
replace with new content rather than relying on parent() as it might
not be the direct parent we want to replace.

Change-Id: I658dae2d3c02adc863cc62ac58d109f3752eb9ff
Signed-off-by: Robert Lyon <email address hidden>

Robert Lyon (robertl-9)
Changed in mahara:
status: In Progress → Fix Committed
Robert Lyon (robertl-9)
Changed in mahara:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.