| author | verrierj |
| Mon, 06 Feb 2012 13:18:01 +0100 | |
| changeset 533 | 4d95862afbb2 |
| parent 167 | fe00e7302efe |
| child 1191 | b6e0b1811723 |
| permissions | -rw-r--r-- |
| 0 | 1 |
|
|
167
fe00e7302efe
Change class and functions names to follow PEP8 formatting standards
verrierj
parents:
13
diff
changeset
|
2 |
def check_access(user, obj): |
|
fe00e7302efe
Change class and functions names to follow PEP8 formatting standards
verrierj
parents:
13
diff
changeset
|
3 |
check_meth = getattr(obj, 'check_access', False) |
| 0 | 4 |
if check_meth: |
5 |
return check_meth(user) |
|
6 |
else: |
|
|
13
97ab7b3191cf
add api to update project, uses psiton
ymh <ymh.work@gmail.com>
parents:
0
diff
changeset
|
7 |
return user.is_staff |