[Koha] How to copy patron permissions?
Michael Kuhn
mik at adminkuhn.ch
Wed Apr 27 22:31:49 NZST 2022
Hi
Thanks to all who answered my e-mail concerning patron permissions!
Raymund Delahunty, Owen Leonard, David Nind, Joel Coehoorn, Michael
Sutherland and Katrin Fischer!
I have saved all the information you gave me for other uses cases. But
in our current library we are hesitating to use non-Koha-standard
methods like external Javascript or plugins. Since we don't need to copy
patron permissions very often we will wait until Koha implements a
proper way to copy patron permissions, e. g. according to
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=30623
For the cases when we actually need to copy patron permissions, for us
the following way seems to be the easiest (instead of manual "box
ticking") :
1. Find the cardnumber (here: 25) of a patron which has the desired
patron permissions, then search for the patron permissions of this patron:
SELECT flags FROM borrowers WHERE cardnumber=25;
2. The result will show the number associated with the staff member’s
permissions, for example:
+-------+
| flags |
+-------+
| 16900 |
+-------+
3. Then update the field "flags" of another patron (here with cardnumber
26) which should receive the same patron permissions:
UPDATE borrowers SET flags=16900 WHERE cardnumber=26;
I have tested this successfully on my demo installation.
Best wishes: Michael
--
Geschäftsführer · Diplombibliothekar BBS, Informatiker eidg. Fachausweis
Admin Kuhn GmbH · Pappelstrasse 20 · 4123 Allschwil · Schweiz
T 0041 (0)61 261 55 61 · E mik at adminkuhn.ch · W www.adminkuhn.ch
More information about the Koha
mailing list