app/soc/views/helper/access.py
changeset 1876 a77d4cdcc052
parent 1870 ea7019607df2
child 1922 800ec7253cf4
equal deleted inserted replaced
1875:69d60793092a 1876:a77d4cdcc052
  1003     entity = group_app_logic.getForFields(fields)
  1003     entity = group_app_logic.getForFields(fields)
  1004 
  1004 
  1005     if entity:
  1005     if entity:
  1006       return
  1006       return
  1007 
  1007 
       
  1008     del fields['applicant']
       
  1009     fields['backup_admin'] = self.user
       
  1010 
       
  1011     entity = group_app_logic.getForFields(fields)
       
  1012 
       
  1013     if entity:
       
  1014       return
       
  1015 
  1008     raise out_of_band.AccessViolation(message_fmt=DEF_NOT_YOUR_ENTITY_MSG)
  1016     raise out_of_band.AccessViolation(message_fmt=DEF_NOT_YOUR_ENTITY_MSG)
  1009 
  1017 
  1010   @allowSidebar
  1018   @allowSidebar
  1011   def checkCanReviewGroupApp(self, django_args, group_app_logic):
  1019   def checkCanReviewGroupApp(self, django_args, group_app_logic):
  1012     """Checks if the group_app in args is valid to be reviewed.
  1020     """Checks if the group_app in args is valid to be reviewed.