source: WAeUP_SRP/trunk/skins/waeup_fceokene/getSchoolFee.py @ 3968

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

resolve FCEOkene #44

File size: 3.4 KB
RevLine 
[3759]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
16ARTS = ('CRS','ISS','HIS','MUS','ECO','GEO','POL','SOS','CCA','ECU','THA','GED','GSE','PES','SPC','ENG ','FRE','ARB','HAU','IGB','YOR','FAA')
17
18# SCS = ('BIO','CHE','HED','MAT','PED','PHY ','CSC','ISC','PHE','AGE','BED','HEC','TED')
19
20d = {}
21
22if not brain.mode.endswith('_sw'):
[3760]23    # PRENCE
[3759]24    if str(brain.level) == '000' and brain.review_state == 'cleared_and_validated':
25        if brain.department in ARTS:
26            d['all'] = 15900
27        else:
28            d['all'] = 16400
[3760]29    # all repeaters
[3802]30    #elif brain.verdict == 'C':
31    #    if brain.department in ARTS:
32    #        d['all'] = 10170
33    #    else:
34    #        d['all'] = 10645
[3760]35    # NCE I fresh
[3759]36    elif str(brain.level) == '100' and brain.review_state == 'cleared_and_validated':
37        if brain.department in ARTS:
38            d['all'] = 13020
39        else:
40            d['all'] = 13495
[3760]41    # NCE II
42    elif str(brain.level) in ('100','110','120') and brain.review_state == 'returning':
[3759]43        if brain.department in ARTS:
44            d['all'] = 12070
45        else:
46            d['all'] = 12545
[3760]47    # NCE III
[3759]48    elif str(brain.level) in ('200','210','220'):
49        if brain.department in ARTS:
50            d['all'] = 12070
51        else:
52            d['all'] = 12545
[3761]53    # NCE III spillover
54    elif str(brain.level) in ('300','310','320') and brain.verdict == 'B':
55        if brain.department in ARTS:
56            d['all'] = 10170
57        else:
58            d['all'] = 10645           
[3759]59    else:
[3760]60        d['all'] = 0   
61
[3759]62else:
63    if str(brain.level) == '100' and brain.review_state == 'cleared_and_validated':
64        if brain.department in ARTS:
65            d['all'] = 21900
66        else:
67            d['all'] = 22400
[3760]68    # all repeaters
[3888]69    elif brain.verdict == 'C':
[3759]70        if brain.department in ARTS:
[3760]71            d['all'] = 16900
72        else:
73            d['all'] = 17400
74    # NCE II           
75    elif str(brain.level) in ('100','110','120') and brain.review_state == 'returning':
76        if brain.department in ARTS:
[3759]77            d['all'] = 18400
78        else:
79            d['all'] = 18900
[3760]80    # NCE III
[3759]81    elif str(brain.level) in ('200','210','220'):
82        if brain.department in ARTS:
83            d['all'] = 20400
84        else:
85            d['all'] = 20900
[3760]86    # NCE IV
[3759]87    elif str(brain.level) in ('300','310','320'):
88        if brain.department in ARTS:
89            d['all'] = 18400
90        else:
91            d['all'] = 18900
[3760]92    # NCE V
[3759]93    elif str(brain.level) in ('400','410','420'):
94        if brain.department in ARTS:
95            d['all'] = 18400
96        else:
97            d['all'] = 18900
[3761]98    # NCE V spillover
99    elif str(brain.level) in ('500','510','520') and brain.verdict == 'B':
100        if brain.department in ARTS:
101            d['all'] = 16900
102        else:
103            d['all'] = 17400           
[3759]104    else:
[3761]105        d['all'] = 0               
[3759]106
107
[3761]108
[3759]109next_info = context.getNextInfo(brain)
110next_session_str = next_info['next_session_str']
111d['next_session_id'] = next_info['next_session_id']
112d['description'] = "School Fee for Session %s" % next_session_str
113
114return d
Note: See TracBrowser for help on using the repository browser.