Bugzilla – Attachment 10206 Details for
Bug 8231
Warning on Check in if borrower is restricted
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
proposed patch #1
0001-Bug-8231-reminder-when-checking-in-for-a-restricted-.patch (text/plain), 2.98 KB, created by
Adrien SAURAT
on 2012-06-11 13:49:11 UTC
(
hide
)
Description:
proposed patch #1
Filename:
MIME Type:
Creator:
Adrien SAURAT
Created:
2012-06-11 13:49:11 UTC
Size:
2.98 KB
patch
obsolete
>From 8c740e6e74c27510b0887c126a001145242a1909 Mon Sep 17 00:00:00 2001 >From: Lyon3 Team <koha@univ-lyon3.fr> >Date: Mon, 11 Jun 2012 14:45:24 +0100 >Subject: [PATCH] Bug 8231: reminder when checking in for a restricted patron > >If a patron is restricted, a warning will appear on the return >page when checking in. >--- > C4/Circulation.pm | 6 +++++- > circ/returns.pl | 4 ++++ > .../intranet-tmpl/prog/en/modules/circ/returns.tt | 3 +++ > 3 files changed, 12 insertions(+), 1 deletions(-) > >diff --git a/C4/Circulation.pm b/C4/Circulation.pm >index 9b523e3..74398d6 100644 >--- a/C4/Circulation.pm >+++ b/C4/Circulation.pm >@@ -1677,7 +1677,11 @@ sub AddReturn { > > # fix fine days > my $debardate = _FixFineDaysOnReturn( $borrower, $item, $issue->{date_due} ); >- $messages->{'Debarred'} = $debardate if ($debardate); >+ if ($debardate) { >+ $messages->{'Debarred'} = $debardate; >+ } elsif ($borrower->{'debarred'}) { >+ $messages->{'PrevDebarred'} = $borrower->{'debarred'}; >+ } > } > > # find reserves..... >diff --git a/circ/returns.pl b/circ/returns.pl >index bd60d42..17b43b2 100755 >--- a/circ/returns.pl >+++ b/circ/returns.pl >@@ -46,6 +46,7 @@ use C4::Koha; # FIXME : is it still useful ? > use C4::RotatingCollections; > use Koha::DateUtils; > use Koha::Calendar; >+use C4::Dates qw/format_date/; > > my $query = new CGI; > >@@ -470,6 +471,9 @@ foreach my $code ( keys %$messages ) { > $err{debarborrowernumber} = $borrower->{borrowernumber}; > $err{debarname} = "$borrower->{firstname} $borrower->{surname}"; > } >+ elsif ( $code eq 'PrevDebarred' ) { >+ $err{prevdebarred} = format_date( $messages->{'PrevDebarred'} ); >+ } > else { > die "Unknown error code $code"; # note we need all the (empty) elsif's above, or we die. > # This forces the issue of staying in sync w/ Circulation.pm >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/returns.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/circ/returns.tt >index 835724f..fded74c 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/returns.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/circ/returns.tt >@@ -338,6 +338,9 @@ $(document).ready(function () { > [% IF ( errmsgloo.debarred ) %] > <p class="problem"><a href="/cgi-bin/koha/circ/circulation.pl?borrowernumber=[% errmsgloo.debarborrowernumber %]">[% errmsgloo.debarname %]([% errmsgloo.debarcardnumber %])</a> is now debarred until [% errmsgloo.debarred | $KohaDates %] </p> > [% END %] >+ [% IF ( errmsgloo.prevdebarred ) %] >+ <p class="problem"><b>REMINDER: </b>Patron is restricted until [% errmsgloo.prevdebarred %]</p> >+ [% END %] > [% END %] > [% IF ( soundon ) %] > <audio src="/intranet-tmpl/prog/sound/critical.ogg" autoplay="autoplay" autobuffer="autobuffer"></audio> >-- >1.7.4.1 >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 8231
:
10206
|
10584
|
10585
|
10586
|
15332
|
16263
|
17273
|
18077
|
20581
|
21080
|
22883
|
24220
|
24230
|
24273