diff --git a/koha-tmpl/intranet-tmpl/prog/en/includes/circ-patron-search-results.inc b/koha-tmpl/intranet-tmpl/prog/en/includes/circ-patron-search-results.inc new file mode 100644 index 0000000000..c60395bd55 --- /dev/null +++ b/koha-tmpl/intranet-tmpl/prog/en/includes/circ-patron-search-results.inc @@ -0,0 +1,40 @@ + +Patron selection + + + + + + + + + + + + [% FOREACH borrower IN borrowers %] + [% IF ( destination == "circ" ) %] + + + [% ELSE %] + + + [% END %] + + + + + + [% END %] + +
NameCard numberCategoryLibraryAddress
[% borrower.surname %], [% borrower.firstname %]
[% borrower.surname %], [% borrower.firstname %][% borrower.cardnumber %][% borrower.categorycode %][% borrower.branchcode %][% borrower.address %]
diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation.tt index cd3fc35567..b6537620e3 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation.tt @@ -91,10 +91,6 @@ $(document).ready(function() { } }); - $(".clickable").click(function() { - window.document.location = $(this).data('url'); - }); - [% IF !( CircAutoPrintQuickSlip == 'clear' ) %] // listen submit to trigger qslip on empty checkout $('#mainform').bind('submit',function() { @@ -107,22 +103,6 @@ $(document).ready(function() { $("#onsite_checkout").click(function(){ toggle_onsite_checkout(); }); - - var table = $("#table_borrowers").dataTable($.extend(true, {}, dataTablesDefaults, { - "aoColumnDefs": [ - { "aTargets": [ 0 ], "bSortable": false, "bSearchable": false }, - ], - "aaSorting": [ 2, "asc" ], - "sDom": "t", - "iDisplayLength": -1 - })); - $(table).find('tbody tr').filter(':has(:radio:checked)').end().click(function(event) { - $('#table_borrowers tbody tr').removeClass('selected'); - $(this).addClass('selected'); - if (event.target.type !== 'radio') { - $(':radio', this).prop('checked', 'true') - } - }); }); //]]> @@ -594,40 +574,9 @@ No patron matched [% message %] [% IF ( borrowers ) %] [% INCLUDE 'patron-toolbar.inc' %] -
- -
- Patron selection - -[% IF (forceallow) %][% END %] - - - - - - - - - - - - - - - - [% FOREACH borrower IN borrowers %] - - - - - - - - [% END %] - -
NameCardnumberCategoryLibraryAddress
[% borrower.surname %], [% borrower.firstname %][% borrower.cardnumber %][% borrower.categorycode %][% borrower.branchcode %][% borrower.address %]
+
+ [% INCLUDE 'circ-patron-search-results.inc' destination = "circ" %]
- [% ELSE %] diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/reserve/request.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/reserve/request.tt index f6e5276aea..c2365b30cb 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/reserve/request.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/reserve/request.tt @@ -29,21 +29,6 @@ $(document).ready(function() { $(".suspend_until_datepicker, .datepickerfrom, .datepickerto").datepicker("option", "minDate", 1); [% END %] - var table = $("#table_borrowers").dataTable($.extend(true, {}, dataTablesDefaults, { - "aoColumnDefs": [ - { "aTargets": [ 0 ], "bSortable": false, "bSearchable": false }, - ], - "aaSorting": [[ 2, "asc" ]], - "sDom": "t", - "iDisplayLength": -1 - })); - $(table).find('tbody tr').filter(':has(:radio:checked)').end().click(function(event) { - $('#table_borrowers tbody tr').removeClass('selected'); - $(this).addClass('selected'); - if (event.target.type !== 'radio') { - $(':radio', this).prop('checked', 'true') - } - }); var my_table = $("#requestspecific").dataTable($.extend(true, {}, dataTablesDefaults, { 'bPaginate': false, "sDom": '<"top pager"ilf>t', @@ -254,8 +239,9 @@ function checkMultiHold() {

Patron not found

No patron with this name, please, try another

[% END %]
+
+ [% UNLESS borrowers %] -
Enter patron card number or partial name:
@@ -263,33 +249,7 @@ function checkMultiHold() {
[% ELSE %] -
- - - - - - - - - - - - - [% FOREACH borrower IN borrowers %] - - - - - - - - - [% END %] - -
NameCardnumberCategoryLibraryAddress
[% borrower.surname %], [% borrower.firstname %][% borrower.cardnumber %][% borrower.categorycode %][% borrower.branchcode %][% borrower.address %]
- -
+ [% INCLUDE 'circ-patron-search-results.inc' destination = "holds" %]
[% END %]