223 'org_student': 'deny', #('checkHasActiveRoleForScope', student_logic), |
223 'org_student': 'deny', #('checkHasActiveRoleForScope', student_logic), |
224 'user': 'checkIsUser', |
224 'user': 'checkIsUser', |
225 'user_self': ('checkIsUserSelf', 'scope_path'), |
225 'user_self': ('checkIsUserSelf', 'scope_path'), |
226 } |
226 } |
227 |
227 |
|
228 #: the depths of various scopes to other scopes |
|
229 # the 0 entries are not used, and are for clarity purposes only |
|
230 SCOPE_DEPTH = { |
|
231 'sponsor': (sponsor_logic, {'sponsor': 0}), |
|
232 'program': (program_logic, {'sponsor': 1, 'program': 0}), |
|
233 'org': (org_logic, {'sponsor': 2, 'program': 1, 'org': 0}), |
|
234 } |
|
235 |
228 def __init__(self, params): |
236 def __init__(self, params): |
229 """Adopts base.rights as rights if base is set. |
237 """Adopts base.rights as rights if base is set. |
230 """ |
238 """ |
231 |
239 |
232 base = params.get('rights') if params else None |
240 base = params.get('rights') if params else None |