Bugzilla – Attachment 21314 Details for
Bug 6739
expired patrons not blocked from opac actions
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
[PASSED QA] Bug 6739 - expired patrons not blocked from opac actions - Followup 2
PASSED-QA-Bug-6739---expired-patrons-not-blocked-f.patch (text/plain), 6.83 KB, created by
Katrin Fischer
on 2013-09-22 14:52:32 UTC
(
hide
)
Description:
[PASSED QA] Bug 6739 - expired patrons not blocked from opac actions - Followup 2
Filename:
MIME Type:
Creator:
Katrin Fischer
Created:
2013-09-22 14:52:32 UTC
Size:
6.83 KB
patch
obsolete
>From 8a6bfc40dca27b4c2048c289cc47a46808cc8754 Mon Sep 17 00:00:00 2001 >From: Kyle M Hall <kyle@bywatersolutions.com> >Date: Thu, 2 May 2013 14:16:51 -0400 >Subject: [PATCH] [PASSED QA] Bug 6739 - expired patrons not blocked from opac > actions - Followup 2 > >* Hide renewal column, buttons and links >* Fixes minor bug where upper-right table links would show even if renewal impossible >* Cleans up some of the template formatting ( whitespace changes only ) > >Signed-off-by: Owen Leonard <oleonard@myacpl.org> >Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de> >--- > koha-tmpl/opac-tmpl/prog/en/modules/opac-user.tt | 30 ++++++++++++++-------- > opac/opac-user.pl | 1 + > 2 files changed, 20 insertions(+), 11 deletions(-) > >diff --git a/koha-tmpl/opac-tmpl/prog/en/modules/opac-user.tt b/koha-tmpl/opac-tmpl/prog/en/modules/opac-user.tt >index 8c28613..da91011 100644 >--- a/koha-tmpl/opac-tmpl/prog/en/modules/opac-user.tt >+++ b/koha-tmpl/opac-tmpl/prog/en/modules/opac-user.tt >@@ -11,8 +11,9 @@ var MSG_CONFIRM_DELETE_HOLD = _("Are you sure you want to cancel this hold?"); > var MSG_CONFIRM_SUSPEND_HOLDS = _("Are you sure you want to suspend all holds?"); > var MSG_CONFIRM_RESUME_HOLDS = _("Are you sure you want to resume all suspended holds?"); > >- $(function() { >- $('#opac-user-views').tabs(); >+ $(document).ready(function(){ >+ >+ $('#opac-user-views').tabs(); > > var dTables = $("#checkoutst,#holdst,#overduest"); > dTables.each(function(){ >@@ -27,8 +28,10 @@ var MSG_CONFIRM_RESUME_HOLDS = _("Are you sure you want to resume all suspended > })); > }); > >-[% IF ( GoogleJackets ) %]KOHA.Google.GetCoverFromIsbn();[% END %] >- [% IF ( OpacRenewalAllowed && canrenew && !userdebarred ) %]$("#renewselected").submit(function(){ >+ [% IF ( GoogleJackets ) %]KOHA.Google.GetCoverFromIsbn();[% END %] >+ >+ [% IF ( OpacRenewalAllowed && canrenew && !userdebarred ) %] >+ $("#renewselected").submit(function(){ > valid = false; > $("input[type=checkbox]").each(function(){ > if($(this).is(':checked')){ >@@ -46,9 +49,14 @@ var MSG_CONFIRM_RESUME_HOLDS = _("Are you sure you want to resume all suspended > $("#renewall_link").live('click',function(){ > $("#renewall").submit(); > }); >- $("#checkoutst caption").append("<div id=\"renewcontrols\"><a id=\"renewselected_link\" href=\"#\">"+_("Renew selected")+"</a> <a id=\"renewall_link\" href=\"#\">"+_("Renew all")+"</a></div>");[% END %] >+ [% IF ( canrenew && !userdebarred && OpacRenewalAllowed && !( borrower.is_expired && borrower.BlockExpiredPatronOpacActions ) ) %] >+ $("#checkoutst caption").append("<div id=\"renewcontrols\"><a id=\"renewselected_link\" href=\"#\">"+_("Renew selected")+"</a> <a id=\"renewall_link\" href=\"#\">"+_("Renew all")+"</a></div>"); >+ [% END %] >+ [% END %] >+ > $( "#suspend_until" ).datepicker({ minDate: 1 }); // Require that "until date" be in the future >- }); >+ >+ }); > //]]> > </script> > </head> >@@ -105,7 +113,7 @@ var MSG_CONFIRM_RESUME_HOLDS = _("Are you sure you want to resume all suspended > <string>Please note:</string> > <span> > Your account renewal failed because of the following: >- [% FOREACH error IN RENEW_ERROR.split('|') %] >+ [% FOREACH error IN RENEW_ERROR.split('\|') %] > [% IF error == 'card_expired' %] > Your account has expired. Please contact the library for more information. > [% ELSIF error == 'too_many' %] >@@ -162,7 +170,7 @@ var MSG_CONFIRM_RESUME_HOLDS = _("Are you sure you want to resume all suspended > [% UNLESS ( item_level_itypes ) %]<th>Item type</th> [% END %] > [% IF ( show_barcode ) %]<th>Barcode</th>[% END %] > <th>Call No.</th> >- [% IF ( OpacRenewalAllowed ) %] >+ [% IF ( OpacRenewalAllowed && !( borrower.is_expired && borrower.BlockExpiredPatronOpacActions ) ) %] > <th class="nosort">Renew</th> > [% END %] > [% IF ( OPACFinesTab ) %] >@@ -210,7 +218,7 @@ var MSG_CONFIRM_RESUME_HOLDS = _("Are you sure you want to resume all suspended > [% UNLESS ( item_level_itypes ) %]<td class="itype">[% IF ( ISSUE.imageurl ) %]<img src="[% ISSUE.imageurl %]" title="[% ISSUE.description %]" alt="[% ISSUE.description %]" />[% END %] [% ISSUE.description %]</td>[% END %] > [% IF ( show_barcode ) %]<td class="barcode">[% ISSUE.barcode %]</td>[% END %] > <td class="call_no">[% ISSUE.itemcallnumber %]</td> >- [% IF ( OpacRenewalAllowed ) %] >+ [% IF ( OpacRenewalAllowed && !( borrower.is_expired && borrower.BlockExpiredPatronOpacActions ) ) %] > <td class="renew">[% IF ( ISSUE.status ) %][% IF ( canrenew ) %]<input type="checkbox" name="item" value="[% ISSUE.itemnumber %]"/> <a href="/cgi-bin/koha/opac-renew.pl?from=opac_user&item=[% ISSUE.itemnumber %]&borrowernumber=[% ISSUE.borrowernumber %]">Renew</a>[% END %] <span class="renewals">([% ISSUE.renewsleft %] of [% ISSUE.renewsallowed %] renewals remaining)</span> > [% ELSE %] > Not renewable[% IF ( ISSUE.too_many ) %] <span class="renewals">([% ISSUE.renewsleft %] of [% ISSUE.renewsallowed %] renewals remaining)</span>[% ELSE %][% IF ( ISSUE.on_reserve ) %] <span class="renewals">(On hold)</span>[% END %][% END %] >@@ -225,11 +233,11 @@ var MSG_CONFIRM_RESUME_HOLDS = _("Are you sure you want to resume all suspended > </tr> > [% END %]</tbody> > </table> >- [% IF ( canrenew && !userdebarred && OpacRenewalAllowed ) %] >+ [% IF ( canrenew && !userdebarred && OpacRenewalAllowed && !( borrower.is_expired && borrower.BlockExpiredPatronOpacActions ) ) %] > <input type="submit" value="Renew Selected" /> > [% END %] > </form> >- [% IF ( canrenew && !userdebarred && OpacRenewalAllowed ) %] >+ [% IF ( canrenew && !userdebarred && OpacRenewalAllowed && !( borrower.is_expired && borrower.BlockExpiredPatronOpacActions ) ) %] > <form id="renewall" action="/cgi-bin/koha/opac-renew.pl" method="post"> > <input type="hidden" name="from" value="opac_user" /> > <input type="hidden" name="borrowernumber" value="[% borrowernumber %]" /> >diff --git a/opac/opac-user.pl b/opac/opac-user.pl >index 6e3e6a5..07b6b1b 100755 >--- a/opac/opac-user.pl >+++ b/opac/opac-user.pl >@@ -145,6 +145,7 @@ $template->param( BORROWER_INFO => \@bordat, > surname => $borr->{surname}, > showname => $borr->{showname}, > RENEW_ERROR => $renew_error, >+ borrower => $borr, > ); > > #get issued items .... >-- >1.7.9.5
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 6739
:
7814
|
9108
|
16061
|
16063
|
16064
|
16065
|
16069
|
16071
|
16072
|
17356
|
17357
|
17463
|
17464
|
17466
|
17517
|
17518
|
17907
|
17908
|
17909
|
18041
|
18042
|
18043
|
19553
|
19554
|
19555
|
19558
|
19559
|
19560
|
19678
|
19679
|
19993
|
19994
|
19995
|
19996
|
19997
|
20641
|
20642
|
20643
|
20644
|
20645
|
21312
|
21313
|
21314
|
21315
|
21316
|
21317
|
24385
|
24386
|
24387
|
24388
|
24389
|
24390
|
24391
|
24392
|
25158
|
25159
|
25160
|
25161
|
25162
|
25163
|
25164
|
25165
|
25231
|
25232
|
25233
|
26546
|
26547
|
26548
|
26549
|
26550
|
26551
|
26552
|
26553
|
26836
|
26837
|
26838
|
26839
|
26840
|
26841
|
26842
|
26843