added ability to view picklist entries if you can view the picklist
authorerickson <erickson@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Tue, 19 Feb 2008 22:28:57 +0000 (22:28 +0000)
committererickson <erickson@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Tue, 19 Feb 2008 22:28:57 +0000 (22:28 +0000)
git-svn-id: svn://svn.open-ils.org/ILS/branches/acq-experiment@8783 dcc99617-32d9-48b4-a31d-7c20da2025e4

Open-ILS/src/perlmods/OpenILS/Application/Acq/Picklist.pm

index 8309d69..657a515 100644 (file)
@@ -320,8 +320,11 @@ sub retrieve_picklist_entry {
     my $picklist = $e->retrieve_acq_picklist($pl_entry->picklist)
         or return $e->event;
 
-    return OpenILS::Event->new('BAD_PARAMS') 
-        if $picklist->owner != $e->requestor->id;
+    if($picklist->owner != $e->requestor->id) {
+        return $e->event unless 
+            $e->allowed('VIEW_PICKLIST', undef, $picklist);
+    }
+
     return $pl_entry;
 }