source: WAeUP_SRP/trunk/skins/waeup_default/getSessionId.py @ 2043

Last change on this file since 2043 was 2031, checked in by Henrik Bettermann, 17 years ago

enable registering courses for session 05

only drawback: level object for session 05 is not closed after submission (register_courses)

please check

  • Property svn:keywords set to Id
File size: 426 bytes
RevLine 
[1440]1## Script (Python) "getSessionId"
2##bind container=container
3##bind context=context
4##bind namespace=
5##bind script=script
6##bind subpath=traverse_subpath
7##parameters=
8##title=
9##
10# $Id: getSessionId.py 2031 2007-07-18 07:51:47Z henrik $
11"""
[1764]12return the Session Id
[1440]13"""
[1764]14
15# must be changed in 2007/2008; should return only the last two digits
16
[1440]17import DateTime
18now = DateTime.DateTime()
[2031]19if now.month() > 8:
[1707]20    s = "%s" % now.year()
21else:
22    s = "%s" % (now.year() - 1)
23return s
Note: See TracBrowser for help on using the repository browser.