Bug 9882 - Use DataTables on batch modifications pages
Summary: Use DataTables on batch modifications pages
Status: CLOSED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: Templates (show other bugs)
Version: master
Hardware: All All
: P5 - low normal (vote)
Assignee: Owen Leonard
QA Contact:
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-03-21 01:01 UTC by Owen Leonard
Modified: 2014-05-26 21:04 UTC (History)
1 user (show)

See Also:
Change sponsored?: ---
Patch complexity: Small patch
Who signed the patch off:
Text to go in the release notes:
Version(s) released in:


Attachments
Bug 9882 - Use DataTables on batch modifications pages (6.47 KB, patch)
2013-03-21 13:53 UTC, Owen Leonard
Details | Diff | Splinter Review
[Signed off] Bug 9882 - Use DataTables on batch modifications pages (6.50 KB, patch)
2013-03-22 05:21 UTC, Melia Meggs
Details | Diff | Splinter Review
[PASSED QA] Bug 9882 - Use DataTables on batch modifications pages (6.62 KB, patch)
2013-03-30 22:47 UTC, Katrin Fischer
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Owen Leonard 2013-03-21 01:01:56 UTC
The batch modification and deletion pages use the old tablesorter plugin. They should use DataTables instead.
Comment 1 Owen Leonard 2013-03-21 13:53:39 UTC Comment hidden (obsolete)
Comment 2 Melia Meggs 2013-03-21 23:48:34 UTC
Hey Owen,

I am testing this patch, and it seems to mostly work.  Everything in batch item deletion looks great, but I ran into some problems in batch item modification.

In batch item modification:
- Checking and unchecking all work fine
- Hide/show works fine
- On tablesorting, I have a few questions:

1. I'm not sure all of the columns are sorting correctly.  When I sort by Title, it seems to go A to Z from top to bottom mostly.  But when I sort by Current Location or Permanent Location, it seems to go from Z to A from top to bottom.  I don't have info in every column to test (my item types are all the same, for example), but at initial glance I think the tablesorting isn't quite right.

2. I thought that clicking the little arrow again would reverse the sorting, but that doesn't seem to work on any of the columns.

Thanks,

Melia
Comment 3 Owen Leonard 2013-03-22 01:21:24 UTC
(In reply to comment #2)
> - On tablesorting, I have a few questions:

I'm not sure what's going on Melia, I don't see either of those problems. Sorting on all columns appears to be working correctly for me. Can you please try clearing your browser cache and testing again?
Comment 4 Melia Meggs 2013-03-22 05:15:56 UTC
Hhmm, clearing the cache didn't fix it.  I tried in both Firefox and Chrome, but something's still not right for me.  However, I have been having other weird browser problems this week, so it is probably just me and not the patch.  I might have to let someone else test this one to be sure.
Comment 5 Melia Meggs 2013-03-22 05:21:48 UTC Comment hidden (obsolete)
Comment 6 Melia Meggs 2013-03-22 05:22:24 UTC
Never mind, I got it. :)  All is working now.
Comment 7 Katrin Fischer 2013-03-30 22:47:26 UTC
Created attachment 17065 [details] [review]
[PASSED QA] Bug 9882 - Use DataTables on batch modifications pages

The batch modification pages (edit and delete) use the old tablesorter
plugin. They should use DataTables instead. This patch makes the
following changes:

- Remove tablesorter plugin from batchMod.tt where it was unused.
- Replace tablesorter assets with DataTables assets on batch edit and
  batch delete pages.
- Replace tablesorter code with DataTables code in batchMod.js, which
  provides table sorting functionality for both batch templates.
- Move position of batchMod.js script inclusion so that DataTables
  assets are loaded first.
- Remove inline table sorting code from batch edit page since it is
  provided by batchMod.js

To test, load barcodes on both the batch edit and batch delete pages.
Test JavaScript-based functionality on each results page:

- Check/Uncheck all
- Hide/show columns
- Table sorting on a variety of different kinds of data columns

Batch operations should complete normally.
There should be no JavaScript error on the batch operation "landing
page" (batchMod.tt).

Signed-off-by: Melia Meggs <melia@bywatersolutions.com>
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
All tests and QA script pass.
Checked both patches, no problems found.
Comment 8 Jared Camins-Esakov 2013-03-31 00:34:16 UTC
This patch has been pushed to master.