Bug 17466: Show number of outstanding issues when checking in
Test plan: 1) Apply patch 2) Checkout more then one item to a borrower 3) Check one of that items 4) Note, that on in returns table there is a button with number of outstanding issues in patron column. The button should take you to checking out page 5) When the outstanding issues count is 0, there is no button Signed-off-by: Radek Šiman <rbit@rbit.cz> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
This commit is contained in:
parent
80a9a7f997
commit
13f3d0cbec
|
|
@ -50,6 +50,7 @@ use C4::RotatingCollections;
|
|||
use Koha::AuthorisedValues;
|
||||
use Koha::DateUtils;
|
||||
use Koha::Calendar;
|
||||
use Koha::Issues;
|
||||
|
||||
my $query = new CGI;
|
||||
|
||||
|
|
@ -578,6 +579,7 @@ foreach ( sort { $a <=> $b } keys %returneditems ) {
|
|||
$ri{bortitle} = $b->{'title'};
|
||||
$ri{bornote} = $b->{'borrowernotes'};
|
||||
$ri{borcategorycode}= $b->{'categorycode'};
|
||||
$ri{borissuescount} = Koha::Issues->count( { borrowernumber => $b->{'borrowernumber'} } );
|
||||
}
|
||||
else {
|
||||
$ri{borrowernumber} = $riborrowernumber{$_};
|
||||
|
|
|
|||
|
|
@ -767,6 +767,9 @@ $(document).ready(function () {
|
|||
<a href="/cgi-bin/koha/members/moremember.pl?borrowernumber=[% riloo.borrowernumber %]">
|
||||
[% riloo.borsurname %], [% riloo.borfirstname %] ([% riloo.borcategorycode %])
|
||||
</a>
|
||||
[% IF riloo.borissuescount %]
|
||||
<a class="btn btn-mini" href="/cgi-bin/koha/circ/circulation.pl?borrowernumber=[% riloo.borrowernumber %]">Issues: [% riloo.borissuescount %]</a>
|
||||
[% END %]
|
||||
[% ELSE %]Not checked out[% END %]</td>
|
||||
<td class="ci-note">
|
||||
[% IF ( riloo.bornote ) %]<p><span class="circ-hlt patron-note">[% riloo.bornote %]</p></span>[% END %]
|
||||
|
|
|
|||
Loading…
Reference in New Issue