https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=41133

            Bug ID: 41133
           Summary: Suggestions table sharing localStorage for all tabs
                    can prevent records from loading
   Initiative type: ---
        Sponsorship ---
            status:
           Product: Koha
           Version: Main
          Hardware: All
                OS: All
            Status: NEW
          Severity: normal
          Priority: P5 - low
         Component: Acquisitions
          Assignee: [email protected]
          Reporter: [email protected]
        QA Contact: [email protected]

On suggestion.pl the local storage DataTables_acqui_suggestions_suggestions
which saves the state for pagination is shared for all tabs, which can cause
tabs to load with a bad state and fail to load records.

To recreate:
1. Use ktd --dbshell to add a bunch of random suggestions with different
statuses:
   INSERT INTO suggestions (suggestedby, suggesteddate, title, status)
   SELECT borrowernumber, '2025-10-29', firstname, ELT(0.5 + RAND() *6,
'ASKED', 'CHECKED', 'ACCEPTED', 'REJECTED', 'ORDERED', 'AVAILABLE' ) from
borrowers;
2. If you are lucky you will have one tab with more than 20 records and one
with less than 20, if not use the ui to adjust the statuses so that you do
3. Click on a tab with more than 20 records
4. Click Next > to go to the second page
5. Notice in local storage now DataTables_acqui_suggestions_suggestions.start
is now 20
6. Click on a tab with fewer than 20 records
7. Notice the table says something illogical like:
   Showing 21 to 11 of 11 entries
8. And no records load :(
9. Click <<First to fix the pagination issue
10. Notice DataTables_acqui_suggestions_suggestions.start is now 0 again
11. The table loads with records :)
    Showing 1 to 11 of 11 entries

-- 
You are receiving this mail because:
You are the assignee for the bug.
You are watching all bug changes.
_______________________________________________
Koha-bugs mailing list
[email protected]
https://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

Reply via email to