[open-ils-commits] r624 - conifer/trunk/circ (pzed)
svn at svn.open-ils.org
svn at svn.open-ils.org
Tue Aug 18 14:48:44 EDT 2009
Author: pzed
Date: 2009-08-18 14:48:39 -0400 (Tue, 18 Aug 2009)
New Revision: 624
Modified:
conifer/trunk/circ/circ_permit_copy.js
Log:
fix to allow Law Faculty to borrow stuff
Modified: conifer/trunk/circ/circ_permit_copy.js
===================================================================
--- conifer/trunk/circ/circ_permit_copy.js 2009-08-18 15:31:43 UTC (rev 623)
+++ conifer/trunk/circ/circ_permit_copy.js 2009-08-18 18:48:39 UTC (rev 624)
@@ -74,7 +74,32 @@
}
} // end permissions for Windsor Leddy
+// set permissions for Windsor Law
+if (copy.circ_lib.shortname == 'OWAL') {
+ // only Law external borrowers can borrow Law items
+ if (patronProfile == 'Readers' && patron.home_ou.shortname <> 'OWAL'){
+ result.events.push('COPY_CIRC_NOT_ALLOWED');
+ }
+
+ // permit circulations for the following circ modifiers to all patrons not excluded above
+ var circ_allow_list = ['LAW MONO'];
+
+ // add permissions for patron groups who are not external borrowers
+ if (patronProfile == 'Faculty' || patronProfile == 'Graduate' || patronProfile == 'Undergraduate' || patronProfile == 'Staff members') {
+ circ_allow_list = circ_allow_list.concat('LAW RES1D', 'LAW RES3D', 'LAW RES3H', 'LAW RES5H');
+ }
+
+ // faculty can borrow non-circulating items and serials
+ if (patronProfile == 'Faculty') {
+ circ_allow_list = circ_allow_list.concat('LAW NOCIRC', 'LAW SERIAL');
+ }
+
+ if ( ! testCircAllow(circ_allow_list) ) {
+ result.events.push('COPY_CIRC_NOT_ALLOWED');
+ }
+} // end permissions for Windsor Law
+
if( ! isTrue(isRenewal) ) {
if(copyStatus != 'Available' &&
copyStatus != 'On holds shelf' && copyStatus != 'Reshelving' ) {
More information about the open-ils-commits
mailing list