source: WAeUP_SRP/trunk/skins/waeup_aaue/getSchoolFee.py @ 4056

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

resolve aaue #23

File size: 3.9 KB
RevLine 
[3841]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"""
[3872]14MBL= ('MBA','MPAD','LLMCPL','LLMPIL')
[3841]15
16d = {}
17
[4014]18d['all'] = 0
19
[3872]20if brain.mode.endswith('_ft'):
[3898]21    # fresh full-time Foundation
[3872]22    if str(brain.level) == '000' and brain.review_state == 'cleared_and_validated':
[3898]23        if brain.entry_mode == 'rm_ft' and brain.lga.startswith('edo'):
[4014]24            d['all'] = 65000
[3872]25        else:
[4014]26            d['all'] = 75000
[3898]27    # fresh tull-time students INE
[3873]28    elif str(brain.level) == '100' and brain.review_state == 'cleared_and_validated' and brain.faculty == 'INE':
29        if brain.lga.startswith('edo'):
[4014]30            d['all'] = 44000
[3872]31        else:
[4014]32            d['all'] = 49000
[3898]33    # returning full-time students INE
34    elif str(brain.level) in ('100','200','300','400','110','210','310','410') and brain.review_state == 'returning' and brain.faculty == 'INE':
[3873]35        if brain.lga.startswith('edo'):
[4014]36            d['all'] = 26300
[3872]37        else:
[4014]38            d['all'] = 31300
[3898]39    # postgrad full-time students (fresh)
[3872]40    elif str(brain.level) == ('600') and brain.review_state == 'cleared_and_validated':
[3873]41        if brain.lga.startswith('edo'):
[3872]42            d['all'] = 62500
[3873]43        elif brain.lga == 'foreigner':
[3872]44            d['all'] = 189500
[3873]45        else:
46            d['all'] = 69500
[3898]47    # MBL students (fresh or returning)       
[3907]48    elif str(brain.level) in ('700','800','710','810') and brain.course in MBL:
[3873]49        if brain.lga.startswith('edo'):
[3872]50            d['all'] = 89500
[3873]51        elif brain.lga == 'foreigner':
[3872]52            d['all'] = 269500
[3873]53        else:
54            d['all'] = 99500
[3898]55    # non-MBL students (fresh or returning)   
[3873]56    elif str(brain.level) in ('700','800','710','810'):
57        if brain.lga.startswith('edo'):
[3872]58            d['all'] = 69500
[3873]59        if brain.lga == 'foreigner':
[3872]60            d['all'] = 219500
[3873]61        else:
62            d['all'] = 79500
[3898]63    # PHD Students       
64    elif str(brain.level) in ('900','910','1000','1010'):
[3873]65        if brain.lga.startswith('edo'):
[3872]66            d['all'] = 99500
[3873]67        if brain.lga == 'foreigner':
[3872]68            d['all'] = 269500
[3873]69        else:
[3898]70            d['all'] = 109500         
[4014]71
72elif brain.mode == 'dp_pt':
73    # fresh part-time Diploma students
74    if str(brain.level) == '100' and brain.review_state == 'cleared_and_validated':
75        if brain.lga.startswith('edo'):
76            d['all'] = 65000
77        else:
78            d['all'] = 75000
79           
80    # returning part-time Diploma students
81    elif str(brain.level) in ('100','200','300','400','110','210','310','410') and brain.review_state == 'returning':
[3873]82        if brain.lga.startswith('edo'):
[4014]83            d['all'] = 50000
84        else:
85            d['all'] = 60000
86       
87elif brain.mode.endswith('_pt'):
88    # fresh part-time students
[4025]89    if str(brain.level) in ('100','200') and brain.review_state == 'cleared_and_validated':
[4014]90        if brain.lga.startswith('edo'):
[3872]91            d['all'] = 45000
92        else:
93            d['all'] = 55000
[4014]94           
95    # returning part-time students
96    elif str(brain.level) in ('100','200','300','400','110','210','310','410') and brain.review_state == 'returning':
[3873]97        if brain.lga.startswith('edo'):
[3872]98            d['all'] = 30000
99        else:
100            d['all'] = 40000
[4014]101
102
[3872]103    # postgrad part-time students
[3873]104    elif str(brain.level) == '600' and brain.review_state == 'cleared_and_validated':
105        if brain.lga.startswith('edo'):
[3872]106            d['all'] = 64500
[4014]107        elif brain.lga == 'foreigner':
[3872]108            d['all'] = 219500
[3873]109        else:
110            d['all'] = 74500
[3841]111
112
113next_info = context.getNextInfo(brain)
114next_session_str = next_info['next_session_str']
115d['next_session_id'] = next_info['next_session_id']
116d['description'] = "School Fee for Session %s" % next_session_str
117
[4014]118return d
Note: See TracBrowser for help on using the repository browser.