## Script (Python) "getSessionId"
##bind container=container
##bind context=context
##bind namespace=
##bind script=script
##bind subpath=traverse_subpath
##parameters=session
##title=
##
# $Id: getNextSessionId.py 1771 2007-05-11 11:37:16Z henrik $
"""
return the next Session Id
"""

if session != context.getSessionId()[-2:]:
    ns = int(session) + 1
else:
    ns = int(session)
ns = "%02d" % ns
ns_str = context.portal_vocabularies.sessions.get(ns)

return ns,ns_str
