Fix for Bug 6728, Table sorter for receiving acquisitions
authorOwen Leonard <oleonard@myacpl.org>
Wed, 17 Aug 2011 20:04:55 +0000 (16:04 -0400)
committerChris Cormack <chrisc@catalyst.net.nz>
Tue, 23 Aug 2011 03:07:36 +0000 (15:07 +1200)
Signed-off-by: Nicole C. Engard <nengard@bywatersolutions.com>
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
koha-tmpl/intranet-tmpl/prog/en/modules/acqui/parcel.tt

index 8ccc42d..b54dc96 100644 (file)
@@ -4,12 +4,23 @@
 [% INCLUDE 'doc-head-close.inc' %]
 [% INCLUDE 'greybox.inc' %]
 <script type="text/javascript" src="[% yuipath %]/json/json-min.js"></script>
-<script type="text/JavaScript">
+<script type="text/javascript" src="[% themelang %]/lib/jquery/plugins/jquery.tablesorter.min.js"></script>
+<script type="text/javascript">
 //<![CDATA[
 
     var rowsToCollapse = 5;
 
+       $.tablesorter.addParser({
+           id: 'articles',
+           is: function(s) {return false;  },
+           format: function(s) { return s.toLowerCase().replace(/^(the|an|a) /,''); },
+           type: 'text'
+       });
+
     $(document).ready(function(){
+    $("#pendingt").tablesorter({
+               headers: { 2: { sorter: 'articles' },3: { sorter: false },7:{sorter:false}}
+    });
 
        rowCountPending  = $("#pendingt tbody.filterclass tr").length;
        rowCountReceived = $("#receivedt tbody.filterclass tr").length;