code: def checkUserManage(self):
          
          granted = False
          can_access = self.checkUserAccess()
  
          if can_access is True:
              pm = getToolByName(self, 'portal_membership')
              edit_allowed = pm.checkPermission(EditWorksheet, self)
              if edit_allowed:
                  # Check if the current user is the WS's current analyst
                  member = pm.getAuthenticatedMember()
                  analyst = self.getAnalyst().strip()
                  if analyst != _c(member.getId()):
                      # Has management privileges?
                      if pm.checkPermission(ManageWorksheets, self):
                          granted = True
                  else:
                      granted = True
  
          return granted
docs: Checks if the current user has granted access to this worksheet
              and if has also privileges for managing it.