Bug 12105 - Remove duplicated plugin jquery.dataTables.columnFilter.js
Summary: Remove duplicated plugin jquery.dataTables.columnFilter.js
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: Testopia
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-04-17 19:17 UTC by Owen Leonard
Modified: 2015-06-04 23:30 UTC (History)
3 users (show)

See Also:
Change sponsored?: ---
Patch complexity: Small patch
Bot Control: ---
When did the bot last check this:
Who signed the patch off:
Text to go in the release notes:


Attachments
Bug 12105 - Remove duplicated plugin jquery.dataTables.columnFilter.js (34.81 KB, patch)
2014-04-17 19:40 UTC, Owen Leonard
Details | Diff | Splinter Review
[SIGNED OFF] Bug 12105 - Remove duplicated plugin jquery.dataTables.columnFilter.js (35.02 KB, patch)
2014-04-21 22:21 UTC, M. Tompsett
Details | Diff | Splinter Review
Bug 12105 - Remove duplicated plugin jquery.dataTables.columnFilter.js (35.07 KB, patch)
2014-04-22 15:59 UTC, Jonathan Druart
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Owen Leonard 2014-04-17 19:17:16 UTC
There are copies of the DataTables plugin jquery.dataTables.columnFilter.js in both intranet-tmpl/lib/jquery/plugins and intranet-tmpl/prog/en/lib/jquery/plugins. The only one we should have is the one outside translated templates.
Comment 1 Owen Leonard 2014-04-17 19:40:32 UTC Comment hidden (obsolete)
Comment 2 M. Tompsett 2014-04-21 19:55:57 UTC
$ grep jquery.dataTables.columnFilter.js `find .` | cut -f1 -d':'
Binary file ./.git/index matches
./koha-tmpl/intranet-tmpl/lib/jquery/plugins/jquery.dataTables.columnFilter.js
./koha-tmpl/intranet-tmpl/prog/en/modules/acqui/parcel.tt
./koha-tmpl/intranet-tmpl/prog/en/modules/tools/manage-marc-import.tt
./koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/detail.tt
./koha-tmpl/intranet-tmpl/prog/en/lib/jquery/plugins/jquery.dataTables.columnFilter.js
./koha-tmpl/intranet-tmpl/prog/fr-FR/modules/acqui/parcel.tt
./koha-tmpl/intranet-tmpl/prog/fr-FR/modules/tools/manage-marc-import.tt
./koha-tmpl/intranet-tmpl/prog/fr-FR/modules/catalogue/detail.tt
./koha-tmpl/intranet-tmpl/prog/fr-FR/lib/jquery/plugins/jquery.dataTables.columnFilter.js

The fr-FR template files will be regenerated from en template files, so they can be ignored.

There are two copies of the same file, and yes the non-language version should be used.

./koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/detail.tt uses the [% interface %] version, which is the correct one.

./koha-tmpl/intranet-tmpl/prog/en/modules/tools/manage-marc-import.tt loads the javascript file, but does not use it.
Comment 3 M. Tompsett 2014-04-21 20:27:20 UTC
One question. Is Order Line supposed to sort string-based and not numerically?
Comment 4 M. Tompsett 2014-04-21 22:21:18 UTC Comment hidden (obsolete)
Comment 5 Jonathan Druart 2014-04-22 15:59:30 UTC
Created attachment 27426 [details] [review]
Bug 12105 - Remove duplicated plugin jquery.dataTables.columnFilter.js

This patch removes a redundant copy of the DataTables plugin
jquery.dataTables.columnFilter.js and corrects two templates.

The path to the plugin has been modified in acqui/parcel.tt:

- Go to Acquisitions and search for a vendor.
- Open the detail page for that vendor.
- Click the "Receive shipments" button.
- Select an invoice to view.
- In the table of titles, confirm that the column header search forms
  work to filter column data.

In the template for the Staged MARC management page the plugin has been
removed as it is unused. A couple of markup corrects have been made.
Confirm that table sorting is unaffected by going to Administration ->
Staged MARC management, clicking a staged MARC file, and viewing the
table of items in that batch.

There should be no more remaining instances of this path in the
templates:

[% themelang %]/lib/jquery/plugins/jquery.dataTables.columnFilter.js

Signed-off-by: Mark Tompsett <mtompset@hotmail.com>

NOTE: I believe the sort order of the Order Line column is
      strange, but unrelated to this patch. The search area
      functions (filtering, paging, page size, etc.) worked
      fine.

Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Comment 6 Galen Charlton 2014-04-23 12:44:31 UTC
Pushed to master.  Thanks, Owen!
Comment 7 Fridolin SOMERS 2014-09-17 14:36:01 UTC
Pushed to 3.14.x, will be in 3.14.11