Bug 11721 - Use new DataTables include in suggestions template
authorOwen Leonard <oleonard@myacpl.org>
Fri, 7 Feb 2014 21:02:06 +0000 (16:02 -0500)
committerGalen Charlton <gmc@esilibrary.com>
Mon, 10 Feb 2014 15:56:50 +0000 (15:56 +0000)
This patch modifies the template for the suggestions page to use
the new DataTables include. This simplifies the inclusion of assets and
updates to the latest DataTables version.

Sorting is now configured to exclude articles when sorting the title
column.

To test, apply the patch and view the suggestions page (Acquisitions ->
Suggestions). Sorting of suggestions should work correctly.

Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz>
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Passes all tests and QA script.

Note: the columsn fund and status are not sortable/searchable
before and after applying the patch.

Signed-off-by: Galen Charlton <gmc@esilibrary.com>
koha-tmpl/intranet-tmpl/prog/en/modules/suggestion/suggestion.tt

index cd5b958..2f1cfb0 100644 (file)
@@ -29,9 +29,7 @@
 [% END %]
 [% IF ( op_else ) %]
 <link rel="stylesheet" type="text/css" href="[% themelang %]/css/datatables.css" />
-<script type="text/javascript" src="[% themelang %]/lib/jquery/plugins/jquery.dataTables.min.js"></script>
-[% INCLUDE 'datatables-strings.inc' %]
-<script type="text/javascript" src="[% themelang %]/js/datatables.js"></script>
+[% INCLUDE 'datatables.inc' %]
 <script type="text/javascript" src="[% themelang %]/lib/jquery/plugins/jquery.checkboxes.min.js"></script>
 <script type="text/javascript">
 // <![CDATA[
@@ -58,6 +56,9 @@ $(document).ready(function() {
         "aoColumnDefs": [
             { "aTargets": [ 0, -1, -2 ], "bSortable": false, "bSearchable": false },
         ],
+        "aoColumns": [
+            null,{ "sType": "anti-the" },null,null,null,null,null
+        ],
         "aLengthMenu": [[10, 20, 50, 100, -1], [10, 20, 50, 100, "All"]],
         "iDisplayLength": 20,
         "sPaginationType": "four_button"