Bugzilla – Attachment 27105 Details for
Bug 12048
Doesn't display other libraries subscriptions when superlibrarian user
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
[PASSED QA] Bug 12048 - Doesn't display other libraries subscriptions when superlibrarian user
PASSED-QA-Bug-12048---Doesnt-display-other-librari.patch (text/plain), 2.87 KB, created by
Katrin Fischer
on 2014-04-14 20:54:27 UTC
(
hide
)
Description:
[PASSED QA] Bug 12048 - Doesn't display other libraries subscriptions when superlibrarian user
Filename:
MIME Type:
Creator:
Katrin Fischer
Created:
2014-04-14 20:54:27 UTC
Size:
2.87 KB
patch
obsolete
>From 8b43a4df91da263192fa44eef59fea760cbc06b5 Mon Sep 17 00:00:00 2001 >From: =?UTF-8?q?Fr=C3=A9d=C3=A9ric=20Demians?= <f.demians@tamil.fr> >Date: Tue, 8 Apr 2014 17:26:18 +0200 >Subject: [PATCH] [PASSED QA] Bug 12048 - Doesn't display other libraries > subscriptions when superlibrarian user > >This is a regression in master and 3.14. When a user has superlibrian >permissions, a search on serials subscriptions must display other libraries >subscriptions even when IndependentBranches syspref is enabled. > >To reproduce/test the bug/patch: > >1. Enable IndependentBranches (i.e. 'Prevent' staff...) >2. Login as a user not having superlibrarian permission >3. Search for a serial subscription on: > /cgi-bin/koha/serials/serials-search.pl >4. Search a title which has at least 2 subscriptions: one in the user branch, > and one in another branch >5. On the result page, just 1 subscription is displayed: the one attached to > the userbranch > => this is normal >6. Login as a user having superlibrarian permission >7. Repeat step 3-5. >8. You get the same result as 5. You should have seen all subscriptions. > That's what you get after applying this patch. > >Signed-off-by: Mark Tompsett <mtompset@hotmail.com> > >NOTE: I tested a variation. My superlibrarian was a branch that > was not the same as the non-superlibrarian. The serial was > the same branch as the non-superlibrarian. Without the > patch, the superlibrarian saw nothing, with the patch it > saw the serial as expected. > Also, remember the superserials permission can affect the > results. I successfully changed the branch of the > subscription, and then it ceased to show up with > superserials not granted to the non-superlibrarian. > I corrected the system preference name in the text here. > >Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de> >Superlibrarian permission now allows to see all subscriptions >independent from the branch. >Passes all tests and QA script. > >But the superserials permission appears broken to me before >and after this patch. If I have superserials - the search >doesn't show all subscriptions. If I don't have superserials >I can still edit any subscription accessing the subscription >detail page through the serial collection page or accessing >the detail page directly by manipulating the URL. >--- > C4/Serials.pm | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > >diff --git a/C4/Serials.pm b/C4/Serials.pm >index 6c035d5..2b7fd51 100644 >--- a/C4/Serials.pm >+++ b/C4/Serials.pm >@@ -740,7 +740,7 @@ sub SearchSubscriptions { > $subscription->{cannotedit} = not can_edit_subscription( $subscription ); > $subscription->{cannotdisplay} = > ( C4::Context->preference("IndependentBranches") && >- C4::Context->userenv && >+ (!C4::Context->IsSuperLibrarian()) && > $subscription->{branchcode} ne C4::Context->userenv->{'branch'} ) ? 1 : 0; > } > >-- >1.8.3.2
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 12048
:
26903
|
27083
|
27098
| 27105 |
30563