[Bug 23575] New: Template error causes item search to be submitted multiple times
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=23575 Bug ID: 23575 Summary: Template error causes item search to be submitted multiple times Change sponsored?: --- Product: Koha Version: master Hardware: All OS: All Status: ASSIGNED Severity: normal Priority: P5 - low Component: Templates Assignee: oleonard@myacpl.org Reporter: oleonard@myacpl.org QA Contact: testopia@bugs.koha-community.org Blocks: 23565 The submit handler for the item search form has been accidentally nested inside a function which loops through the <select> forms on the page. This means the submitForm() function fires 8 times. Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=23565 [Bug 23565] Add columns configuration and export options to item search results -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=23575 Owen Leonard <oleonard@myacpl.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |Needs Signoff Patch complexity|--- |Trivial patch -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=23575 --- Comment #1 from Owen Leonard <oleonard@myacpl.org> --- Created attachment 92672 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=92672&action=edit Bug 23575: Template error causes item search to be submitted multiple times This patch corrects the item search template so that the submit handler is not nested inside an unrelated loop. The change should have no outward effect on the behavior of the item search other than making it faster. To observe the bug in action, open your browser's developer tools and click the "Network" tab. Filter the output to only "XHR" and perform an item search. You should see multiple requests. To test, apply the patch and perform an item search. It should behave normally. Check the browser's "Network" monitor again to verify that only one request is being sent. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=23575 Owen Leonard <oleonard@myacpl.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Blocks| |23543 Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=23543 [Bug 23543] Adding Withdrawn to the Item Search -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=23575 Lucas Gass <lucas@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #92672|0 |1 is obsolete| | --- Comment #2 from Lucas Gass <lucas@bywatersolutions.com> --- Created attachment 92709 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=92709&action=edit Bug 23575: Template error causes item search to be submitted multiple times This patch corrects the item search template so that the submit handler is not nested inside an unrelated loop. The change should have no outward effect on the behavior of the item search other than making it faster. To observe the bug in action, open your browser's developer tools and click the "Network" tab. Filter the output to only "XHR" and perform an item search. You should see multiple requests. To test, apply the patch and perform an item search. It should behave normally. Check the browser's "Network" monitor again to verify that only one request is being sent. Signed-off-by: Lucas Gass <lucas@bywatersolutions.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=23575 Lucas Gass <lucas@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |lucas@bywatersolutions.com 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=23575 Bouzid Fergani <bouzid.fergani@inlibro.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #92709|0 |1 is obsolete| | --- Comment #3 from Bouzid Fergani <bouzid.fergani@inlibro.com> --- Created attachment 92820 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=92820&action=edit Bug 23575: Template error causes item search to be submitted multiple times This patch corrects the item search template so that the submit handler is not nested inside an unrelated loop. The change should have no outward effect on the behavior of the item search other than making it faster. To observe the bug in action, open your browser's developer tools and click the "Network" tab. Filter the output to only "XHR" and perform an item search. You should see multiple requests. To test, apply the patch and perform an item search. It should behave normally. Check the browser's "Network" monitor again to verify that only one request is being sent. Signed-off-by: Lucas Gass <lucas@bywatersolutions.com> Signed-off-by: Bouzid Fergani <bouzid.fergani@inlibro.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=23575 Katrin Fischer <katrin.fischer@bsz-bw.de> 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=23575 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #92820|0 |1 is obsolete| | --- Comment #4 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- Created attachment 92822 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=92822&action=edit Bug 23575: Template error causes item search to be submitted multiple times This patch corrects the item search template so that the submit handler is not nested inside an unrelated loop. The change should have no outward effect on the behavior of the item search other than making it faster. To observe the bug in action, open your browser's developer tools and click the "Network" tab. Filter the output to only "XHR" and perform an item search. You should see multiple requests. To test, apply the patch and perform an item search. It should behave normally. Check the browser's "Network" monitor again to verify that only one request is being sent. Signed-off-by: Lucas Gass <lucas@bywatersolutions.com> Signed-off-by: Bouzid Fergani <bouzid.fergani@inlibro.com> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=23575 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |katrin.fischer@bsz-bw.de --- Comment #5 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- Excellent catch, Owen! -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=23575 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Passed QA |Pushed to master Version(s)| |19.11.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=23575 --- Comment #6 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- Nice work! Pushed to master for 19.11.00 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=23575 Fridolin SOMERS <fridolin.somers@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Version(s)|19.11.00 |19.11.00,19.05.04 released in| | Status|Pushed to master |Pushed to stable CC| |fridolin.somers@biblibre.co | |m --- Comment #7 from Fridolin SOMERS <fridolin.somers@biblibre.com> --- Pushed to 19.05.x for 19.05.04 Great job, what a dirty bug ;) -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=23575 Lucas Gass <lucas@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Pushed to stable |Pushed to oldstable --- Comment #8 from Lucas Gass <lucas@bywatersolutions.com> --- backported to 18.11.x for 18.11.11 -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org