## Script (Python) "index_html" ##bind container=container ##bind context=context ##bind namespace= ##bind script=script ##bind subpath=traverse_subpath ##parameters=batch=None ##title= ## # $Id: student_edit.py 486 2006-09-06 10:09:39Z joachim $ """ return the correct index_html """ request = context.REQUEST redirect = request.RESPONSE.redirect pm = context.portal_membership if pm.isAnonymousUser(): return redirect("%s/srp_anonymous_view" % request.get('URL1')) member = pm.getAuthenticatedMember() roles = member.getRoles() isManager = "Manager" in roles or "SectionManager" in roles isStudent = "Student" in roles if isManager: return redirect("%s/srp_manager_view" % context.absolute_url()) if isStudent: return redirect("%s/srp_anonymous_view" % context.absolute_url())