Bug 9762: (follow-up) Add branchcode to Log circulation and add some override confirmations in action logs, fix typos
Signed-off-by: Martin Renvoize <martin.renvoize@openfifth.co.uk>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
(cherry picked from commit 489780f3f9)
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
This commit is contained in:
parent
4921bb669a
commit
7d038428a5
|
|
@ -2021,6 +2021,7 @@ sub AddIssue {
|
|||
$info = to_json(
|
||||
{
|
||||
issue => $issue->issue_id,
|
||||
branchcode => $issue->branchcode,
|
||||
itemnumber => $item_object->itemnumber,
|
||||
confirmations => $confirmations,
|
||||
forced => $forced
|
||||
|
|
@ -3693,7 +3694,7 @@ sub AddRenewal {
|
|||
},
|
||||
{
|
||||
pretty => 1,
|
||||
cononical => 1
|
||||
canonical => 1
|
||||
}
|
||||
);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -444,7 +444,8 @@ if ( @$barcodes && $op eq 'cud-checkout' ) {
|
|||
}
|
||||
}
|
||||
|
||||
delete $needsconfirmation->{'DEBT'} if ($debt_confirmed);
|
||||
my $needsconfirmationDEBT;
|
||||
$needsconfirmationDEBT = delete $needsconfirmation->{'DEBT'} if ($debt_confirmed);
|
||||
|
||||
if ( $item && C4::Context->preference('ClaimReturnedLostValue') ) {
|
||||
my $autoClaimReturnCheckout = C4::Context->preference('AutoClaimReturnStatusOnCheckout');
|
||||
|
|
@ -547,6 +548,7 @@ if ( @$barcodes && $op eq 'cud-checkout' ) {
|
|||
if ( my $booked = $needsconfirmation->{BOOKED_EARLY} // $alerts->{BOOKED} ) {
|
||||
$datedue = $booked->end_date;
|
||||
}
|
||||
$needsconfirmation->{'DEBT'} = $needsconfirmationDEBT if ($debt_confirmed);
|
||||
my $issue = AddIssue(
|
||||
$patron, $barcode, $datedue,
|
||||
$cancelreserve,
|
||||
|
|
|
|||
|
|
@ -198,7 +198,7 @@
|
|||
[% CASE 'PATRON_CANT' %]
|
||||
<span>Max renewals reached</span>
|
||||
[% CASE 'TOO_MANY' %]
|
||||
<span>Max renewals reached</span>
|
||||
<span>Too many checkout</span>
|
||||
[% CASE 'PREVISSUE' %]
|
||||
<span>Patron was notified of previous issues</span>
|
||||
[% CASE 'NOT_FOR_LOAN' %]
|
||||
|
|
@ -226,11 +226,27 @@
|
|||
[% CASE 'BOOKED_TO_ANOTHER' %]
|
||||
<span>Item was booked to another patron</span>
|
||||
[% CASE 'AGE_RESTRICTION' %]
|
||||
<span>Item has an eage restriction</span>
|
||||
<span>Item has an age restriction</span>
|
||||
[% CASE 'HIGHHOLDS' %]
|
||||
<span>Item had high holds</span>
|
||||
[% CASE 'BIBLIO_ALREADY_ISSUED' %]
|
||||
<span>Biblio was already issued</span>
|
||||
[% CASE 'DEBARRED' %]
|
||||
<span>Patron is restricted</span>
|
||||
[% CASE 'RENEWAL_LIMIT' %]
|
||||
<span>Renewal limit override</span>
|
||||
[% CASE 'UNSEEN_LIMIT' %]
|
||||
<span>Override unseen item restriction</span>
|
||||
[% CASE 'AUTO_TOO_SOON' %]
|
||||
<span>Override auto-renew too soon restriction</span>
|
||||
[% CASE 'AUTO_TOO_LATE' %]
|
||||
<span>Override auto-renew too late restriction</span>
|
||||
[% CASE 'ACCOUNT_EXPIRED' %]
|
||||
<span>Account expired override</span>
|
||||
[% CASE 'ON_RESERVE' %]
|
||||
<span>Override Renew hold for another</span>
|
||||
[% CASE 'TOO_MUCH' %]
|
||||
<span>Override auto-renew too much owing restriction</span>
|
||||
[% CASE %]
|
||||
<span>[% override | html %]</span>
|
||||
[% END %]
|
||||
|
|
|
|||
|
|
@ -339,11 +339,11 @@
|
|||
<a
|
||||
href="/cgi-bin/koha/catalogue/moredetail.pl?itemnumber=[% loopro.json.itemnumber | uri %]&biblionumber=[% loopro.json.biblionumber | uri %]&bi=[% loopro.json.biblioitemnumber | uri %]#item[% loopro.json.itemnumber | uri %]"
|
||||
title="Display detail for this item"
|
||||
>Item [% loopro.json.barcode | html %]</a
|
||||
>Item [% loopro.json.barcode | html %] [% loopro.json.branchcode | html %]</a
|
||||
>
|
||||
</div>
|
||||
[% FOREACH force IN loopro.json.forces %]
|
||||
<div class="forced"> [% PROCESS translare_log_override override=force %] </div>
|
||||
[% FOREACH force IN loopro.json.forced %]
|
||||
<div class="forced"> [% PROCESS translate_log_override override=force %] </div>
|
||||
[% END %]
|
||||
[% FOREACH confirmation IN loopro.json.confirmations %]
|
||||
<div class="confirmed"> [% PROCESS translate_log_override override=confirmation %] </div>
|
||||
|
|
|
|||
|
|
@ -67,6 +67,7 @@ $data->{branchcode} = $branchcode;
|
|||
my $patron = Koha::Patrons->find($borrowernumber);
|
||||
my $item = Koha::Items->find($itemnumber);
|
||||
|
||||
my $confirmations;
|
||||
( $data->{renew_okay}, $data->{error} ) =
|
||||
CanBookBeRenewed( $patron, $item->checkout, $override_limit );
|
||||
|
||||
|
|
@ -75,6 +76,7 @@ if ( $data->{error} && $data->{error} eq 'on_reserve' && C4::Context->preference
|
|||
$data->{renew_okay} = 1;
|
||||
$data->{error} = undef;
|
||||
|
||||
push @{$confirmations}, 'ON_RESERVE' if $override_limit;
|
||||
$message = "Override Renew hold for another";
|
||||
@message = ("Override Renew hold for another");
|
||||
|
||||
|
|
@ -133,7 +135,8 @@ if ( $data->{renew_okay} || ( $seen && $data->{error} eq 'too_unseen' ) ) {
|
|||
itemnumber => $itemnumber,
|
||||
branch => $branchcode,
|
||||
datedue => $date_due,
|
||||
seen => $seen
|
||||
seen => $seen,
|
||||
confirmations => $confirmations
|
||||
}
|
||||
);
|
||||
$data->{date_due} = output_pref( { dt => $date_due, as_due_date => 1 } );
|
||||
|
|
|
|||
|
|
@ -181,6 +181,7 @@ if ($do_it) {
|
|||
$decoded->{biblionumber} = $item->biblionumber;
|
||||
$decoded->{biblioitemnumber} = $item->biblionumber;
|
||||
$decoded->{barcode} = $item->barcode;
|
||||
$decoded->{branchcode} = C4::Context->userenv ? C4::Context->userenv->{'branch'} : undef;
|
||||
}
|
||||
$result->{'json'} = $decoded;
|
||||
} else {
|
||||
|
|
|
|||
Loading…
Reference in New Issue