From d4464826adf1e510a3c19cffcc52fa450c923b28 Mon Sep 17 00:00:00 2001 From: Andrew Isherwood Date: Fri, 1 Mar 2019 11:47:16 +0000 Subject: [PATCH] Bug 21063: (follow-up) Make patron col consistent As per comment #44 here: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=21063#c44 --- .../prog/en/modules/ill/ill-requests.tt | 43 +++++++++------------- 1 file changed, 17 insertions(+), 26 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/ill/ill-requests.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/ill/ill-requests.tt index 667c3e1480..ab4b3a916d 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/ill/ill-requests.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/ill/ill-requests.tt @@ -63,8 +63,8 @@
  • - - + +
  • @@ -518,8 +518,6 @@ Pages Type Order ID - Patron ID - Patron barcode Patron Biblio ID Branch @@ -615,7 +613,7 @@ var sel = $('#illfilter_status option:selected').val(); if (sel && sel.length > 0) { activeFilters[me] = function() { - table.api().column(15).search(sel); + table.api().column(13).search(sel); } } else { if (activeFilters.hasOwnProperty(me)) { @@ -647,7 +645,7 @@ var sel = $('#illfilter_branchname option:selected').val(); if (sel && sel.length > 0) { activeFilters[me] = function() { - table.api().column(14).search(sel); + table.api().column(12).search(sel); } } else { if (activeFilters.hasOwnProperty(me)) { @@ -660,14 +658,14 @@ $('#illfilter_branchname').val(''); } }, - barcode: { + patron: { listener: function() { - var me = 'barcode'; - $('#illfilter_barcode').change(function() { - var val = $('#illfilter_barcode').val(); + var me = 'patron'; + $('#illfilter_patron').change(function() { + var val = $('#illfilter_patron').val(); if (val && val.length > 0) { activeFilters[me] = function() { - table.api().column(11).search(val); + table.api().column(10).search(val); } } else { if (activeFilters.hasOwnProperty(me)) { @@ -677,7 +675,7 @@ }); }, clear: function() { - $('#illfilter_barcode').val(''); + $('#illfilter_patron').val(''); } }, dateModified: { @@ -736,7 +734,8 @@ if ( row.patron_firstname ) { patronLink = patronLink + row.patron_firstname + ' '; } - patronLink = patronLink + row.patron_surname + ''; + patronLink = patronLink + row.patron_surname + + ' (' + row.patron_cardnumber + ')' + ''; return patronLink; }; @@ -841,9 +840,6 @@ updated: { name: _("Updated on"), }, - patron_cardnumber: { - name: _("Cardnumber") - }, patron: { skipSanitize: true, func: createPatronLink @@ -976,20 +972,15 @@ { // When sorting 'placed', we want to use the // unformatted column 'aTargets': [ 'placed_formatted'], - 'iDataSort': 16 + 'iDataSort': 14 }, { // When sorting 'updated', we want to use the // unformatted column 'aTargets': [ 'updated_formatted'], - 'iDataSort': 18 - }, - { - 'aTargets': [ 'patron_cardnumber' ], - 'bVisible': false, - 'bSearchable': true + 'iDataSort': 16 } ], - 'aaSorting': [[ 18, 'desc' ]], // Default sort, updated descending + 'aaSorting': [[ 16, 'desc' ]], // Default sort, updated descending 'processing': true, // Display a message when manipulating 'sPaginationType': "full_numbers", // Pagination display 'deferRender': true, // Improve performance on big datasets @@ -1020,8 +1011,8 @@ var placedEnd = $('#illfilter_dateplaced_end').datepicker('getDate'); var modifiedStart = $('#illfilter_datemodified_start').datepicker('getDate'); var modifiedEnd = $('#illfilter_datemodified_end').datepicker('getDate'); - var rowPlaced = data[16] ? new Date(data[16]) : null; - var rowModified = data[18] ? new Date(data[18]) : null; + var rowPlaced = data[14] ? new Date(data[14]) : null; + var rowModified = data[16] ? new Date(data[16]) : null; var placedPassed = true; var modifiedPassed = true; if (placedStart && rowPlaced && rowPlaced < placedStart) { -- 2.11.0