Allow backup admins to edit org application
authorSverre Rabbelier <srabbelier@gmail.com>
Sun, 15 Mar 2009 16:30:53 +0000
changeset 1876 a77d4cdcc052
parent 1875 69d60793092a
child 1877 93dfd2d40c0b
Allow backup admins to edit org application Patch by: Sverre Rabbelier
app/soc/views/helper/access.py
--- a/app/soc/views/helper/access.py	Sun Mar 15 16:30:26 2009 +0000
+++ b/app/soc/views/helper/access.py	Sun Mar 15 16:30:53 2009 +0000
@@ -1005,6 +1005,14 @@
     if entity:
       return
 
+    del fields['applicant']
+    fields['backup_admin'] = self.user
+
+    entity = group_app_logic.getForFields(fields)
+
+    if entity:
+      return
+
     raise out_of_band.AccessViolation(message_fmt=DEF_NOT_YOUR_ENTITY_MSG)
 
   @allowSidebar