28 |
28 |
29 from soc.logic import dicts |
29 from soc.logic import dicts |
30 from soc.logic.models import organization as org_logic |
30 from soc.logic.models import organization as org_logic |
31 from soc.logic.models import org_admin as org_admin_logic |
31 from soc.logic.models import org_admin as org_admin_logic |
32 from soc.logic.models import org_app as org_app_logic |
32 from soc.logic.models import org_app as org_app_logic |
|
33 from soc.logic.models import student as student_logic |
33 from soc.views.helper import access |
34 from soc.views.helper import access |
34 from soc.views.helper import decorators |
35 from soc.views.helper import decorators |
35 from soc.views.helper import dynaform |
36 from soc.views.helper import dynaform |
36 from soc.views.helper import redirects |
37 from soc.views.helper import redirects |
37 from soc.views.helper import params as params_helper |
38 from soc.views.helper import params as params_helper |
63 rights['edit'] = [('checkIsMyActiveRole', org_admin_logic.logic)] |
64 rights['edit'] = [('checkIsMyActiveRole', org_admin_logic.logic)] |
64 rights['delete'] = ['checkIsDeveloper'] |
65 rights['delete'] = ['checkIsDeveloper'] |
65 rights['invite'] = [('checkHasActiveRoleForScope', |
66 rights['invite'] = [('checkHasActiveRoleForScope', |
66 org_admin_logic.logic)] |
67 org_admin_logic.logic)] |
67 rights['accept_invite'] = [('checkCanCreateFromRequest', 'org_admin'), |
68 rights['accept_invite'] = [('checkCanCreateFromRequest', 'org_admin'), |
68 'checkIsNotStudentForProgramOfOrg'] |
69 ('checkIsNotStudentForProgramOfOrg', [org_logic.logic, |
|
70 student_logic.logic])] |
69 rights['process_request'] = [ |
71 rights['process_request'] = [ |
70 ('checkHasActiveRoleForScope', org_admin_logic.logic), |
72 ('checkHasActiveRoleForScope', org_admin_logic.logic), |
71 ('checkCanProcessRequest', 'org_admin')] |
73 ('checkCanProcessRequest', 'org_admin')] |
72 rights['manage'] = [ |
74 rights['manage'] = [ |
73 ('checkIsAllowedToManageRole', [org_admin_logic.logic, |
75 ('checkIsAllowedToManageRole', [org_admin_logic.logic, |