## Script (Python) "students_index" ##bind container=container ##bind context=context ##bind namespace= ##bind script=script ##bind subpath=traverse_subpath ##parameters=batch=None ##title= ## # $Id: students_index.py 1193 2007-01-03 22:15:42Z henrik $ """ return the current students_index_html """ request = context.REQUEST redirect = request.RESPONSE.redirect mtool = context.portal_membership member = mtool.getAuthenticatedMember() if mtool.isAnonymousUser(): return redirect("%s/srp_anonymous_view" % context.portal_url()) students_url = "%s/campus/students" % (context.portal_url()) campus_url = "%s/campus" % (context.portal_url()) if "ClearanceOfficers" in member.getGroups(): return redirect("%s/search_students" % campus_url) if context.isSectionOfficer(): return redirect("%s/search_students" % campus_url) if context.isStudent(): id = str(member) return redirect("%s/%s/student_view" % (students_url, id))