source: WAeUP_SRP/trunk/skins/waeup_aaua/getSchoolFee.py @ 4954

Last change on this file since 4954 was 3866, checked in by Henrik Bettermann, 16 years ago

clean-up of ZMI custom folders

File size: 1.8 KB
Line 
1## Script (Python) "getSchoolFee"
2##bind container=container
3##bind context=context
4##bind namespace=
5##bind script=script
6##bind subpath=traverse_subpath
7##parameters=brain=None
8##title=
9##
10# $Id: getSchoolFee.py 2534 2007-11-05 06:37:12Z henrik $
11"""
12return SchoolFee
13"""
14
15
16d = {}
17
18if brain.mode == 'ug_sw': 
19    if str(brain.level) == '100':    # both 100 fresh and 100 returning who register for 200
20        d['all'] = 35000
21    else:
22        d['all'] = 30000
23elif brain.mode == 'pg_sw': 
24    d['all'] = 35000
25elif brain.mode == 'dp_pt': 
26    if str(brain.level) in ('100',) and brain.review_state == 'cleared_and_validated':    # only 100 fresh
27        d['all'] = 40000
28    else:
29        d['all'] = 35000
30elif brain.mode == 'ug_pt': 
31    if str(brain.level) in ('100','200',) and brain.review_state == 'cleared_and_validated':    # only 100 or 200 fresh
32        d['all'] = 50000
33    else:
34        d['all'] = 45000
35elif brain.mode == 'pg_pt': 
36    if str(brain.level) == '600' and brain.review_state == 'cleared_and_validated':    # only 600 fresh
37        d['all'] = 60000
38    elif str(brain.level) == '600' and brain.verdict == 'C':                           # 600 repeaters
39        d['all'] = 55000
40    elif str(brain.level) == '700' and brain.review_state == 'cleared_and_validated':  # only 700 fresh                                             # going to register for 700
41        d['all'] = 75000     
42    elif str(brain.level) == '600':                                                    # going to register for 700
43        d['all'] = 75000       
44    else:
45        d['all'] = 65000
46else:
47    d['all'] = 0
48
49
50next_info = context.getNextInfo(brain)
51next_session_str = next_info['next_session_str']
52d['next_session_id'] = next_info['next_session_id']
53d['description'] = "School Fee for Session %s" % next_session_str
54
55return d
Note: See TracBrowser for help on using the repository browser.