[open-ils-commits] r19222 - trunk/Open-ILS/web/js/ui/default/actor/user (erickson)
svn at svn.open-ils.org
svn at svn.open-ils.org
Wed Jan 19 17:27:20 EST 2011
Author: erickson
Date: 2011-01-19 17:27:14 -0500 (Wed, 19 Jan 2011)
New Revision: 19222
Modified:
trunk/Open-ILS/web/js/ui/default/actor/user/register.js
Log:
if this user does not have permission to edit an existing user, disable the save and clone buttons
Modified: trunk/Open-ILS/web/js/ui/default/actor/user/register.js
===================================================================
--- trunk/Open-ILS/web/js/ui/default/actor/user/register.js 2011-01-19 22:27:14 UTC (rev 19221)
+++ trunk/Open-ILS/web/js/ui/default/actor/user/register.js 2011-01-19 22:27:14 UTC (rev 19222)
@@ -148,6 +148,13 @@
input.widget.attr('disabled', true).attr('readOnly', true);
}
+
+ if(!patron.isnew() && !checkGrpAppPerm(patron.profile()) && patron.id() != openils.User.user.id()) {
+ // we are not allowed to edit this user, so disable the save option
+ saveButton.attr('disabled', true);
+ saveCloneButton.attr('disabled', true);
+ }
+
lock_ready = true;
}
More information about the open-ils-commits
mailing list