Bugzilla – Attachment 84240 Details for
Bug 22134
Add account expiration information to patron details
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 22134: Add account expiration information to patron details
Bug-22134-Add-account-expiration-information-to-pa.patch (text/plain), 7.60 KB, created by
Katrin Fischer
on 2019-01-20 11:49:43 UTC
(
hide
)
Description:
Bug 22134: Add account expiration information to patron details
Filename:
MIME Type:
Creator:
Katrin Fischer
Created:
2019-01-20 11:49:43 UTC
Size:
7.60 KB
patch
obsolete
>From 1b5a367e8ae79a1a1bba091a9238738aca4557af Mon Sep 17 00:00:00 2001 >From: Owen Leonard <oleonard@myacpl.org> >Date: Tue, 15 Jan 2019 14:53:07 +0000 >Subject: [PATCH] Bug 22134: Add account expiration information to patron > details > >This patch modifies the patron detail template in the staff client so >that when a patron's registration is expired a message shows at the top >of the page along with the same "Renew" and "Edit" links which appear on >the checkout page. Links are also shown next the the expiration date in >the body of the page. > >This patch also corrects the capitalization of the "Edit Details" link >on circulation.tt. > >To test, apply the patch and locate a patron record which is expired. > > - On the patron detail page (members/moremember.pl) you should see a > message at the top of the page. > - In the body of the page, next to the expiration date information, you > should see similar message and links. > - On the patron's checkout page the "Edit details" link in the > expiration message should have correct capitalization. > >Signed-off-by: Devinim <kohadevinim@devinim.com.tr> >Signed-off-by: Maryse Simard <maryse.simard@inlibro.com> > >Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> > >Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> >--- > .../intranet-tmpl/prog/en/modules/circ/circulation.tt | 4 ++-- > .../intranet-tmpl/prog/en/modules/members/moremember.tt | 17 +++++++++++++++++ > members/moremember.pl | 16 ++++++++++++++++ > 3 files changed, 35 insertions(+), 2 deletions(-) > >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 3c5a777dc9..12b0548ddb 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation.tt >@@ -656,7 +656,7 @@ No patron matched <span class="ex">[% message | html %]</span> > > [% IF ( warndeparture ) %] > <li><span class="circ-hlt">Expiration:</span> Patron's card will expire soon. >- Patron's card expires on [% expiry | $KohaDates %] <a href="/cgi-bin/koha/members/setstatus.pl?borrowernumber=[% patron.borrowernumber | uri %]&destination=circ&reregistration=y">Renew</a> or <a href="/cgi-bin/koha/members/memberentry.pl?op=modify&destination=circ&borrowernumber=[% patron.borrowernumber | html %]&categorycode=[% categorycode | html %]">Edit Details</a> >+ Patron's card expires on [% expiry | $KohaDates %] <a href="/cgi-bin/koha/members/setstatus.pl?borrowernumber=[% patron.borrowernumber | uri %]&destination=circ&reregistration=y">Renew</a> or <a href="/cgi-bin/koha/members/memberentry.pl?op=modify&destination=circ&borrowernumber=[% patron.borrowernumber | html %]&categorycode=[% categorycode | html %]">Edit details</a> > > </li> > [% END %] >@@ -669,7 +669,7 @@ No patron matched <span class="ex">[% message | html %]</span> > > [% IF ( expired ) %] > <li><span class="circ-hlt">Expiration:</span> Patron's card has expired. >- [% IF ( expiry ) %]Patron's card expired on [% expiry | $KohaDates %][% END %] <a href="/cgi-bin/koha/members/setstatus.pl?borrowernumber=[% patron.borrowernumber | uri %]&destination=circ&reregistration=y">Renew</a> or <a href="/cgi-bin/koha/members/memberentry.pl?op=modify&destination=circ&borrowernumber=[% patron.borrowernumber | html %]&categorycode=[% categorycode | html %]">Edit Details</a> >+ [% IF ( expiry ) %]Patron's card expired on [% expiry | $KohaDates %][% END %] <a href="/cgi-bin/koha/members/setstatus.pl?borrowernumber=[% patron.borrowernumber | uri %]&destination=circ&reregistration=y">Renew</a> or <a href="/cgi-bin/koha/members/memberentry.pl?op=modify&destination=circ&borrowernumber=[% patron.borrowernumber | html %]&categorycode=[% categorycode | html %]">Edit details</a> > > </li> > [% END %] >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/moremember.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/moremember.tt >index a98cbcd8e0..677bf45917 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/moremember.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/moremember.tt >@@ -133,6 +133,17 @@ > [% IF ( lost ) %] > <li class="blocker">Patron's card has been reported lost.</li> > [% END %] >+ [% IF ( expired ) %] >+ <li class="blocker"> >+ <span class="circ-hlt">Expiration:</span> >+ [% IF ( patron.dateexpiry ) %] >+ Patron's card expired on [% patron.dateexpiry | $KohaDates %]. >+ [% ELSE %] >+ Patron's card has expired. >+ [% END %] >+ <a href="/cgi-bin/koha/members/setstatus.pl?borrowernumber=[% patron.borrowernumber | uri %]&destination=circ&reregistration=y">Renew</a> or <a href="/cgi-bin/koha/members/memberentry.pl?op=modify&destination=circ&borrowernumber=[% patron.borrowernumber | html %]&categorycode=[% categorycode | html %]">Edit details</a> >+ </li> >+ [% END %] > </ul> > </div> > [% END %] >@@ -428,6 +439,12 @@ > <span class="label">Expiration date: </span> > [% IF ( was_renewed ) %] > <strong class="reregistrinfo">[% patron.dateexpiry | $KohaDates %]</strong> >+ [% ELSIF ( expired ) %] >+ <span class="blocker"> >+ [% patron.dateexpiry | $KohaDates %] >+ <strong><em>Expired</em></strong> >+ <a href="/cgi-bin/koha/members/setstatus.pl?borrowernumber=[% patron.borrowernumber | uri %]&reregistration=y">Renew</a> or <a href="/cgi-bin/koha/members/memberentry.pl?op=modify]&borrowernumber=[% patron.borrowernumber | html %]&categorycode=[% categorycode | html %]">Edit details</a> >+ </span> > [% ELSE %] > [% patron.dateexpiry | $KohaDates %] > [% END %] >diff --git a/members/moremember.pl b/members/moremember.pl >index 9f06882b8f..e76dcd019b 100755 >--- a/members/moremember.pl >+++ b/members/moremember.pl >@@ -308,6 +308,22 @@ if( $patron_messages->count > 0 ){ > my ( $subtag, $region ) = split '-', $patron->lang; > my $translated_language = C4::Languages::language_get_description( $subtag, $subtag, 'language' ); > >+# if the expiry date is before today ie they have expired >+if ( $patron->is_expired ) { >+ $template->param( >+ expired => "1", >+ flagged => 1 >+ ); >+} >+# check for NotifyBorrowerDeparture >+elsif ( $patron->is_going_to_expire ) { >+ # borrower card soon to expire warn librarian >+ $template->param( >+ "warndeparture" => $patron->dateexpiry, >+ flagged => 1 >+ ); >+} >+ > my $total = $patron->account->balance; > $template->param( > patron => $patron, >-- >2.11.0
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 22134
:
83972
|
83998
|
84147
|
84162
|
84191
|
84214
|
84215
|
84238
| 84240 |
84241