[Bug 14699] New: Intranet search history issues due to DataTables pagination
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14699 Bug ID: 14699 Summary: Intranet search history issues due to DataTables pagination Change sponsored?: --- Product: Koha Version: master Hardware: All OS: All Status: ASSIGNED Severity: normal Priority: P5 - low Component: Searching Assignee: gmcharlt@gmail.com Reporter: julian.maurice@biblibre.com QA Contact: testopia@bugs.koha-community.org DataTables removes hidden rows from the DOM. Because of that, "Select all", "Clear all" and the form submission don't work correctly (basically they act only on the currently displayed page). As OPAC search history doesn't use DataTables, this bug only affects intranet. To reproduce: 1/ Go to your search history page 2/ Make you sure you have at least 21 entries in your search history. If not, do some searches and come back here. 3/ Click "Select all" and change page. The checkboxes on the new page are not checked. 4/ Check some checkboxes on this new page and click "Clear all". Go back to the previous page, checkboxes are still checked. 5/ Check some checkboxes on at least 2 different pages and click "Delete". Only search history entries selected on the current page were deleted. This bug affects both biblio and authority search history. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14699 --- Comment #1 from Julian Maurice <julian.maurice@biblibre.com> --- Created attachment 41734 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=41734&action=edit Bug 14699: Fix intranet search history issues due to pagination DataTables removes hidden rows from the DOM. Because of that, "Select all", "Clear all" and the form submission don't work correctly (basically they act only on the currently displayed page). This patch fixes just that. Test plan: 1/ Go to your search history page 2/ Make you sure you have at least 21 entries in your search history. If not, do some searches and come back here. 3/ Click "Select all" and change page. The checkboxes on the new page should be checked. 4/ Check some checkboxes on this new page and click "Clear all". Go back to the previous page, checkboxes shouldn't be checked. 5/ Check some checkboxes on at least 2 different pages and click "Delete". All selected search history entries should be deleted. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14699 Julian Maurice <julian.maurice@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |Needs Signoff -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14699 Julian Maurice <julian.maurice@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|gmcharlt@gmail.com |julian.maurice@biblibre.com -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14699 Julian Maurice <julian.maurice@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Blocks| |12460 Referenced Bugs: http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=12460 [Bug 12460] Search history: Combine to start a new search -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14699 Zeno Tajoli <z.tajoli@cineca.it> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |z.tajoli@cineca.it Patch complexity|--- |Small patch -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14699 --- Comment #2 from Marc Véron <veron@veron.ch> --- Created attachment 42330 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=42330&action=edit [Signed-off] Bug 14699: Fix intranet search history issues due to pagination DataTables removes hidden rows from the DOM. Because of that, "Select all", "Clear all" and the form submission don't work correctly (basically they act only on the currently displayed page). This patch fixes just that. Test plan: 1/ Go to your search history page 2/ Make you sure you have at least 21 entries in your search history. If not, do some searches and come back here. 3/ Click "Select all" and change page. The checkboxes on the new page should be checked. 4/ Check some checkboxes on this new page and click "Clear all". Go back to the previous page, checkboxes shouldn't be checked. 5/ Check some checkboxes on at least 2 different pages and click "Delete". All selected search history entries should be deleted. Followed test plan. Works as expected. Signed-off-by: Marc Véron <veron@veron.ch> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14699 Marc Véron <veron@veron.ch> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |veron@veron.ch Attachment #41734|0 |1 is obsolete| | -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14699 Marc Véron <veron@veron.ch> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Signed Off -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14699 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |jonathan.druart@bugs.koha-c | |ommunity.org --- Comment #3 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- What you describe is the expected behavior, I think. With your patch if you filter the table and click "select all", it will select all row, even the filtered ones. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14699 --- Comment #4 from Julian Maurice <julian.maurice@biblibre.com> --- (In reply to Jonathan Druart from comment #3)
What you describe is the expected behavior, I think. With your patch if you filter the table and click "select all", it will select all row, even the filtered ones.
Then maybe "select/clear all" should be reworded to something like "select/clear all visible rows" to remove ambuiguity. Or maybe we should make a difference between invisible rows due to pagination and invisible rows due to filtering ? But I believe "Delete" should work on all checked checkboxes, not only the visible ones (and even the filtered ones). -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14699 Zeno Tajoli <z.tajoli@cineca.it> changed: What |Removed |Added ---------------------------------------------------------------------------- CC|z.tajoli@cineca.it | -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14699 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |ASSIGNED -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14699 --- Comment #5 from Julian Maurice <julian.maurice@biblibre.com> --- Created attachment 42449 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=42449&action=edit Bug 14699: Show number of selected searches in search history With the number displayed, it should remove the ambiguity about what "Select all" and "Clear all" do. The number is repeated in the "Delete" confirmation dialog. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14699 Julian Maurice <julian.maurice@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |Needs Signoff -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14699 Nick Clemens <nick@quecheelibrary.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |nick@quecheelibrary.org Status|Needs Signoff |In Discussion --- Comment #6 from Nick Clemens <nick@quecheelibrary.org> --- Moving this to in discussion. I think the expected behavior is somewhere between the original and that with the patches applied. I would expect either: 1 - Preserve current behavior and change just the labels to "Select all visible / clear all visible" 2 - Select all searches but respect filters. If I filter down to 8 searches it should select only those. If my filter finds 21 searches (default 20 visible) it should select all 21, but not searches limited by filter. Labels would say "With ## selected searches: delete" A couple other things from testing: 1 - On master selecting any search past 20 doesn't change the look of the delete button, though it is enabled. It does only function on the visible searches either way i.e. select search 21, button no visibly enabled, but clickable. Select #1 and #21 (with 20 visible) button is enabled, only #1 is deleted. With the patches the link still isn't visibly enabled but will delete all selected regardless of visibility 2 - The phrasing "With selected searches: Delete" is awkward. I think it should be "Delete selected searches" and button can simply be grayed out when none are selected With these patches phrasing would then be "Delete ## selected searches" -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14699 --- Comment #7 from Owen Leonard <oleonard@myacpl.org> --- (In reply to Nick Clemens from comment #6)
2 - Select all searches but respect filters. If I filter down to 8 searches it should select only those. If my filter finds 21 searches (default 20 visible) it should select all 21, but not searches limited by filter. Labels would say "With ## selected searches: delete"
I think this is the correct goal. With a filtered result clicking "select all" shouldn't select lines which are not visible because of the filter. However, with a filtered or unfiltered result clicking "select all" should select records across all pages.
1 - On master selecting any search past 20 doesn't change the look of the delete button, though it is enabled. It does only function on the visible searches either way
Confirmed. Checking a box on any but the first page does not change the appearance of the delete button or show the number of selected lines even though the delete button will work.
2 - The phrasing "With selected searches: Delete" is awkward.
This is a pattern used elsewhere, although it's not quite as useful when there is only one "action" available. See the OPAC list interface where we have "Select titles to: Place hold | Remove from list" ...which changes to: "With selected titles: Place hold | Remove from list" I think the advantage to doing it this way is that the interface is explicit about *why* an option is disabled. -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org