[open-ils-commits] [GIT] Evergreen ILS branch master updated. adc2affe4d525bd9116b3e241b9b4fc4c4e6406c

Evergreen Git git at git.evergreen-ils.org
Wed Jun 10 21:06:28 EDT 2015


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "Evergreen ILS".

The branch, master has been updated
       via  adc2affe4d525bd9116b3e241b9b4fc4c4e6406c (commit)
      from  0898959d4782d422e93341ce9456b72c8207780c (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit adc2affe4d525bd9116b3e241b9b4fc4c4e6406c
Author: Blake Henderson <blake at mobiusconsortium.org>
Date:   Mon Dec 8 15:52:15 2014 -0600

    LP#1194860: You have permission to override some of the failed holds. appearing when it should not for patrons in the OPAC Edit
    
    A quick value check before assigning the override variable.
    This should eliminate the OPAC showing the override option
    for those who do not have the permission.
    
    Signed-off-by: Blake Henderson <blake at mobiusconsortium.org>
    Signed-off-by: Liam Whalen <liam.whalen at bc.libraries.coop>
    Signed-off-by: Ben Shum <bshum at biblio.org>

diff --git a/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader/Account.pm b/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader/Account.pm
index 97364ed..3dae3bf 100644
--- a/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader/Account.pm
+++ b/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader/Account.pm
@@ -1275,7 +1275,10 @@ sub attempt_hold_placement {
                         $hdata->{hold_failed_event} = $result->{last_event};
 
                         if ($result->{age_protected_copy}) {
-                            $hdata->{could_override} = 1;
+                            my %temp = %{$hdata->{hold_failed_event}};
+                            my $theTextcode = $temp{"textcode"};
+                            $theTextcode.=".override";
+                            $hdata->{could_override} = $self->editor->allowed( $theTextcode );
                             $hdata->{age_protect} = 1;
                         } else {
                             $hdata->{could_override} = $result->{place_unfillable} || 
@@ -1285,7 +1288,10 @@ sub attempt_hold_placement {
                         $hdata->{hold_failed_event} = $result->[0];
 
                         if ($result->[3]) { # age_protect_only
-                            $hdata->{could_override} = 1;
+                            my %temp = %{$hdata->{hold_failed_event}};
+                            my $theTextcode = $temp{"textcode"};
+                            $theTextcode.=".override";
+                            $hdata->{could_override} = $self->editor->allowed( $theTextcode );
                             $hdata->{age_protect} = 1;
                         } else {
                             $hdata->{could_override} = $result->[4] || # place_unfillable

-----------------------------------------------------------------------

Summary of changes:
 .../lib/OpenILS/WWW/EGCatLoader/Account.pm         |   10 ++++++++--
 1 files changed, 8 insertions(+), 2 deletions(-)


hooks/post-receive
-- 
Evergreen ILS


More information about the open-ils-commits mailing list