|
Last change
on this file since 2454 was
2454,
checked in by Henrik Bettermann, 19 years ago
|
|
rebuild getNextInfo.py completely
fetch session from portal properties.xml
change all scripts using getSessionId
remove StudentCourseResult? relevant code from event services
make pay_by_sc.py and interswitch_cb.py work (rebuild both)
|
|
File size:
472 bytes
|
| Line | |
|---|
| 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=session |
|---|
| 8 | ##title= |
|---|
| 9 | ## |
|---|
| 10 | # $Id: getNextSessionId.py 1771 2007-05-11 11:37:16Z henrik $ |
|---|
| 11 | """ |
|---|
| 12 | return the next Session Id |
|---|
| 13 | """ |
|---|
| 14 | |
|---|
| 15 | if session != context.getSessionId()[-2:]: |
|---|
| 16 | ns = int(session) + 1 |
|---|
| 17 | else: |
|---|
| 18 | ns = int(session) |
|---|
| 19 | ns = "%02d" % ns |
|---|
| 20 | ns_str = context.portal_vocabularies.sessions.get(ns) |
|---|
| 21 | |
|---|
| 22 | return ns,ns_str |
|---|
Note: See
TracBrowser for help on using the repository browser.