[Bug 31994] New: Clicking the next button of a DataTable loading its data from the HTML does nothing
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31994 Bug ID: 31994 Summary: Clicking the next button of a DataTable loading its data from the HTML does nothing Change sponsored?: --- Product: Koha Version: master Hardware: All OS: All Status: NEW Severity: minor Priority: P5 - low Component: Templates Assignee: oleonard@myacpl.org Reporter: olivier.hubert@inlibro.com QA Contact: testopia@bugs.koha-community.org When the next button of a DataTable with data straight from the HTML is clicked, nothing happens. Additionally, an error can be found in the console similar to: Uncaught TypeError: q is undefined Note that this problem does not occur when the data is sourced using Ajax. Steps to reproduce: 1. Open itemtypes.pl. 2. If there are fewer than 11 item types, create additional item types until there are more than 10, so that the next button can be used. 3. Click on the next button / link. 4. Notice that nothing happens. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31994 Olivier Hubert <olivier.hubert@inlibro.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|oleonard@myacpl.org |olivier.hubert@inlibro.com -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31994 Olivier Hubert <olivier.hubert@inlibro.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |Needs Signoff -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31994 --- Comment #1 from Olivier Hubert <olivier.hubert@inlibro.com> --- Created attachment 142679 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=142679&action=edit Bug 31994: DataTable next button does not work when using data in the HTML This patch resolves the issue that occurs when the next button of a DataTable with data straight from the HTML is clicked. Test plan: 1. Open itemtypes.pl. 2. If there are fewer than 11 item types, create additional item types until there are more than 10, so that the next button can be used. 3. Click on the next button / link. 4. Notice that nothing happens. 5. Apply the patch. 6. Restart plack / memcached if using. 7. Reload itemtypes.pl. 8. Click on the next button / link. 9. Notice that the next page is displayed. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31994 Olivier Hubert <olivier.hubert@inlibro.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Component|Templates |Architecture, internals, | |and plumbing -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31994 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Component|Architecture, internals, |Templates |and plumbing | CC| |oleonard@myacpl.org -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31994 E-P Keskitalo <esa-pekka.keskitalo@helsinki.fi> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |esa-pekka.keskitalo@helsink | |i.fi --- Comment #2 from E-P Keskitalo <esa-pekka.keskitalo@helsinki.fi> --- Cannot reproduce. Works as expected in the current sandbox version without applying the patch. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31994 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |david@davidnind.com --- Comment #3 from David Nind <david@davidnind.com> --- I can reproduce this bug on the latest 21.11 and 21.05. I checked these versions: - master: can't reproduce (works as expected) - 22.05: can't reproduce (works as expected) - 21.11: can reproduce - 21.05: can reproduce - 20.11: can't reproduce (works as expected) -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31994 --- Comment #4 from David Nind <david@davidnind.com> --- Patch doesn't apply on 21.11.13. I haven't changed the status. git bz apply 31994 Bug 31994 - Clicking the next button of a DataTable loading its data from the HTML does nothing 142679 - Bug 31994: DataTable next button does not work when using data in the HTML Apply? [(y)es, (n)o, (i)nteractive] y Applying: Bug 31994: DataTable next button does not work when using data in the HTML Using index info to reconstruct a base tree... M koha-tmpl/intranet-tmpl/prog/en/includes/columns_settings.inc Falling back to patching base and 3-way merge... Auto-merging koha-tmpl/intranet-tmpl/prog/en/includes/columns_settings.inc CONFLICT (content): Merge conflict in koha-tmpl/intranet-tmpl/prog/en/includes/columns_settings.inc error: Failed to merge in the changes. Patch failed at 0001 Bug 31994: DataTable next button does not work when using data in the HTML -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31994 Olivier Hubert <olivier.hubert@inlibro.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |caroline.cyr-la-rose@inlibr | |o.com, | |philippe.blouin@inlibro.com -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31994 Victor Grousset/tuxayo <victor@tuxayo.net> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |victor@tuxayo.net Version|master |21.11 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31994 Lucas Gass <lucas@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |lucas@bywatersolutions.com --- Comment #5 from Lucas Gass <lucas@bywatersolutions.com> --- Olivier, I am also unable to reproduce this issue in either master or 21.11. Your patch applies cleanly in master but does not in 21.11.x Can you confirm which version your patch is intended for? -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31994 --- Comment #6 from Olivier Hubert <olivier.hubert@inlibro.com> --- Hi Lucas, The patch is intended for master only. I have not tested it on any other version so far. I confirm that I am able to reproduce the issue on a clean master, and that applying the patch fixes the issue. However, I can confirm that the bug cannot be reproduced on a Bywater sandbox. I don't understand how that is possible, since the master branch should be the same, as long as it's up-to-date. We run all of our tests on local installations, not using docker images. Do you know if there are differences between the master branch and the version available through KTD? -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31994 --- Comment #7 from Olivier Hubert <olivier.hubert@inlibro.com> --- I figured it out. The problem only occurs if the Default Display Length was never updated through column_settings.pl. When that is the case, the default display length is used, and that variable is a string, not an int, therefore causing the issue. To reproduce, add the following before Step 3 of the test plan: 2a: Run the following SQL query: DELETE FROM tables_settings WHERE tablename = 'table_item_type'; If someone can confirm reproduction on master, I will update the test plan accordingly. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31994 --- Comment #8 from David Nind <david@davidnind.com> --- (In reply to Olivier Hubert from comment #7)
If someone can confirm reproduction on master, I will update the test plan accordingly.
Hi Olivier. I was able to reproduce on the current master (using koha-testing-docker), here is what I did: 1. Followed steps 1-2 in the current test plan. 2. Followed new step 2a. 3. Ran a flush_memcached, restart_all, and cleared the browser cache.[1] 4. The first time I go to Administration > Basic parameters > Item types the behavour as identified occurs. That is, clicking on Next or Last options don't work (from both at the top and bottom of the table). 5. If I click on the menu in the sidebar again (Item types) to refresh the page, then the Next and Last options work as expected. 6. I applied the patch and followed the rest of the test plan, and this resolved the issue. I'm happy to sign off once you have updated the test plan. Thanks for persevering with this! David [1] Clearing the browser cache: I normally use the Firefox Developer Edition, and have set things so that all history, etc., are deleted when it is closed. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31994 Victor Grousset/tuxayo <victor@tuxayo.net> changed: What |Removed |Added ---------------------------------------------------------------------------- Version|21.11 |master -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31994 Olivier Hubert <olivier.hubert@inlibro.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #142679|0 |1 is obsolete| | --- Comment #9 from Olivier Hubert <olivier.hubert@inlibro.com> --- Created attachment 145903 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=145903&action=edit Bug 31994: DataTable next button does not work when using data in the HTML This patch resolves the issue that occurs when the next button of a DataTable with data straight from the HTML is clicked. Test plan: 1. Run the following SQL query on the database: DELETE FROM tables_settings WHERE tablename = 'table_item_type'; 2. Restart plack / memcached if using. 3. Open itemtypes.pl. 4. If there are fewer than 11 item types, create additional item types until there are more than 10, so that the next button can be used. 5. Click on the next button / link. 6. Notice that nothing happens. 7. Apply the patch. 8. Restart plack / memcached if using. 9. Reload itemtypes.pl. 10. Click on the next button / link. 11. Notice that the next page is displayed. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31994 Magnus Enger <magnus@libriotech.no> changed: What |Removed |Added ---------------------------------------------------------------------------- Patch complexity|--- |Trivial patch Status|Needs Signoff |Signed Off -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31994 Magnus Enger <magnus@libriotech.no> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #145903|0 |1 is obsolete| | --- Comment #10 from Magnus Enger <magnus@libriotech.no> --- Created attachment 148899 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=148899&action=edit Bug 31994: DataTable next button does not work when using data in the HTML This patch resolves the issue that occurs when the next button of a DataTable with data straight from the HTML is clicked. Test plan: 1. Run the following SQL query on the database: DELETE FROM tables_settings WHERE tablename = 'table_item_type'; 2. Restart plack / memcached if using. 3. Open itemtypes.pl. 4. If there are fewer than 11 item types, create additional item types until there are more than 10, so that the next button can be used. 5. Click on the next button / link. 6. Notice that nothing happens. 7. Apply the patch. 8. Restart plack / memcached if using. 9. Reload itemtypes.pl. 10. Click on the next button / link. 11. Notice that the next page is displayed. Signed-off-by: Magnus Enger <magnus@libriotech.no> I can reproduce the problem on ktd, after a restart_all and a hard reload of itemtypes.pl. Patch fixes the problem. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31994 Nick Clemens <nick@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Passed QA -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31994 Nick Clemens <nick@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #148899|0 |1 is obsolete| | --- Comment #11 from Nick Clemens <nick@bywatersolutions.com> --- Created attachment 148930 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=148930&action=edit Bug 31994: DataTable next button does not work when using data in the HTML This patch resolves the issue that occurs when the next button of a DataTable with data straight from the HTML is clicked. Test plan: 1. Run the following SQL query on the database: DELETE FROM tables_settings WHERE tablename = 'table_item_type'; 2. Restart plack / memcached if using. 3. Open itemtypes.pl. 4. If there are fewer than 11 item types, create additional item types until there are more than 10, so that the next button can be used. 5. Click on the next button / link. 6. Notice that nothing happens. 7. Apply the patch. 8. Restart plack / memcached if using. 9. Reload itemtypes.pl. 10. Click on the next button / link. 11. Notice that the next page is displayed. Signed-off-by: Magnus Enger <magnus@libriotech.no> I can reproduce the problem on ktd, after a restart_all and a hard reload of itemtypes.pl. Patch fixes the problem. Signed-off-by: Nick Clemens <nick@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31994 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Passed QA |Pushed to master Version(s)| |23.05.00 released in| | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31994 --- Comment #12 from Tomás Cohen Arazi <tomascohen@gmail.com> --- Pushed to master for 23.05. Nice work everyone, thanks! -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31994 Jacob O'Mara <jacob.omara@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Pushed to master |Pushed to stable Version(s)|23.05.00 |23.05.00,22.11.05 released in| | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31994 --- Comment #13 from Jacob O'Mara <jacob.omara@ptfs-europe.com> --- Nice work, thanks everyone! Pushed to 22.11.x for the next release. -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org