## Script (Python) "getSchoolFee" ##bind container=container ##bind context=context ##bind namespace= ##bind script=script ##bind subpath=traverse_subpath ##parameters=brain=None ##title= ## # $Id: getSchoolFee.py 2534 2007-11-05 06:37:12Z henrik $ """ return SchoolFee """ d = {} if brain.mode == 'ug_sw': if str(brain.level) == '100': # both 100 fresh and 100 returning who register for 200 d['all'] = 35000 else: d['all'] = 30000 elif brain.mode == 'pg_sw': d['all'] = 35000 elif brain.mode == 'dp_pt': if str(brain.level) in ('100',) and brain.review_state == 'cleared_and_validated': # only 100 fresh d['all'] = 40000 else: d['all'] = 35000 elif brain.mode == 'ug_pt': if str(brain.level) in ('100','200',) and brain.review_state == 'cleared_and_validated': # only 100 or 200 fresh d['all'] = 50000 else: d['all'] = 45000 elif brain.mode == 'pg_pt': if str(brain.level) == '600' and brain.review_state == 'cleared_and_validated': # only 600 fresh d['all'] = 60000 elif str(brain.level) == '700' and brain.review_state == 'cleared_and_validated': # only 700 fresh # going to register for 700 d['all'] = 75000 elif str(brain.level) == '600' and brain.verdict == 'C': # 600 repeaters d['all'] = 55000 elif str(brain.level) == '600': # going to register for 700 d['all'] = 75000 else: d['all'] = 65000 else: d['all'] = 0 next_info = context.getNextInfo(brain) next_session_str = next_info['next_session_str'] d['next_session_id'] = next_info['next_session_id'] d['description'] = "School Fee for Session %s" % next_session_str return d