The hold ratios report uses the old tablesorter plugin. It should use the DataTables plugin instead.
Created attachment 14788 [details] [review] Bug 9459 - Use DataTables on hold ratios report page Replace the tablesorter plugin with the DataTables plugin on the hold ratios report page. To test, open the hold ratios report (Circulation -> Hold ratios). Confirm that table sorting works correctly.
Created attachment 15084 [details] [review] Bug 9459 - Use DataTables on hold ratios report page Replace the tablesorter plugin with the DataTables plugin on the hold ratios report page. To test, open the hold ratios report (Circulation -> Hold ratios). Confirm that table sorting works correctly. Signed-off-by: Galen Charlton <gmc@esilibrary.com>
QA comment: At least the "Items" column is not correctly sorted (alpha sort: 1, 10, 3). Certainly caused by the <p> tag. + the aLengthMenu should contain 20 instead of 25. Marked as Failed QA.
Created attachment 15102 [details] [review] Bug 9459 [Revised] Use DataTables on hold ratios report page Replace the tablesorter plugin with the DataTables plugin on the hold ratios report page. To test, open the hold ratios report (Circulation -> Hold ratios). Confirm that table sorting works correctly. Revision adds correct pagination options and natural sort for 'items needed' column. Patch now depends on Bug 9431 (http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=9431) which introduces the natural sort plugin.
Created attachment 15181 [details] [review] Bug 9459 [Revised] Use DataTables on hold ratios report page Replace the tablesorter plugin with the DataTables plugin on the hold ratios report page. To test, open the hold ratios report (Circulation -> Hold ratios). Confirm that table sorting works correctly. Revision adds correct pagination options and natural sort for 'items needed' column. Patch now depends on Bug 9431 (http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=9431) which introduces the natural sort plugin. Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
QA comment: I spoke about the second column. I will modified my SO patch. Owen, show yourself if you disagree. Marked as Passed QA.
Created attachment 15224 [details] [review] Bug 9459 [Revised] Use DataTables on hold ratios report page Replace the tablesorter plugin with the DataTables plugin on the hold ratios report page. To test, open the hold ratios report (Circulation -> Hold ratios). Confirm that table sorting works correctly. Revision adds correct pagination options and natural sort for 'items needed' column. Patch now depends on Bug 9431 (http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=9431) which introduces the natural sort plugin. Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com> Amended patch: Apply the natural sort plugin on the first 2 columns
I get a javascript error from this patch: Uncaught TypeError: Property 'natural-asc' of object #<Object> is not a function As a result of the Javascript error (I think), I get the following problematic display: http://screencast.com/t/k4l8TAppdWC
Jared, Yes, this patch depends on Bug 9431.
I will return the status to Passed QA, and revisit this once bug 9431 has been QAed.
Created attachment 15704 [details] [review] Bug 9459 [Revised] Use DataTables on hold ratios report page Replace the tablesorter plugin with the DataTables plugin on the hold ratios report page. To test, open the hold ratios report (Circulation -> Hold ratios). Confirm that table sorting works correctly. Revision adds correct pagination options and natural sort for 'items needed' column. Patch now depends on Bug 9431 (http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=9431) which introduces the natural sort plugin. Further revision corrects template path to datatables assets.
Created attachment 15960 [details] [review] [SIGNED-OFF] Bug 9459 [Revised] Use DataTables on hold ratios report page Replace the tablesorter plugin with the DataTables plugin on the hold ratios report page. To test, open the hold ratios report (Circulation -> Hold ratios). Confirm that table sorting works correctly. Revision adds correct pagination options and natural sort for 'items needed' column. Patch now depends on Bug 9431 (http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=9431) which introduces the natural sort plugin. Further revision corrects template path to datatables assets. Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com> Comment: On top of Bug 9431. Sorting works. No errors.
Hello Owen, Don't you think we can delete the a links in headers? Is it really relevant to keep sorting (without js) only on 1 table? (I suppose it is for the case where javascript is disabled).
ping Owen
Sorry I missed your comment Jonathan. Since we require JS in the staff client I don't see any reason why we need to keep the server-side sort. A separate bug could certainly be created for that. Or is there a reason to let that hold up this patch?
(In reply to comment #15) > Sorry I missed your comment Jonathan. Since we require JS in the staff > client I don't see any reason why we need to keep the server-side sort. A > separate bug could certainly be created for that. Or is there a reason to > let that hold up this patch? No one :) I created a new bug for that (bug 9984).
replace tablesorter with DT on the hold ratios table. Marked as Passed QA.
Created attachment 17169 [details] [review] Bug 9459 [Revised] Use DataTables on hold ratios report page Replace the tablesorter plugin with the DataTables plugin on the hold ratios report page. To test, open the hold ratios report (Circulation -> Hold ratios). Confirm that table sorting works correctly. Revision adds correct pagination options and natural sort for 'items needed' column. Patch now depends on Bug 9431 (http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=9431) which introduces the natural sort plugin. Further revision corrects template path to datatables assets. Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com> Comment: On top of Bug 9431. Sorting works. No errors. Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
This patch has been pushed to master and 3.12.x.