source: main/waeup.custom/trunk/src/waeup/custom/utils/utils.py @ 7897

Last change on this file since 7897 was 7845, checked in by Henrik Bettermann, 13 years ago

Move large dictionaries to custom package.

  • Property svn:keywords set to Id
File size: 6.5 KB
Line 
1## $Id: utils.py 7845 2012-03-12 11:40:52Z henrik $
2##
3## Copyright (C) 2012 Uli Fouquet & Henrik Bettermann
4## This program is free software; you can redistribute it and/or modify
5## it under the terms of the GNU General Public License as published by
6## the Free Software Foundation; either version 2 of the License, or
7## (at your option) any later version.
8##
9## This program is distributed in the hope that it will be useful,
10## but WITHOUT ANY WARRANTY; without even the implied warranty of
11## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
12## GNU General Public License for more details.
13##
14## You should have received a copy of the GNU General Public License
15## along with this program; if not, write to the Free Software
16## Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
17##
18"""Customize general helper utilities for Kofa.
19"""
20import os
21from waeup.kofa.utils.utils import KofaUtils
22
23
24class KofaUtils(KofaUtils):
25    """A collection of methods subject to customization.
26    """
27    PORTAL_LANGUAGE = 'en'
28
29    PREFERRED_LANGUAGES_DICT = {
30        'en':(1, u'English'),
31        'fr':(2, u'Français'),
32        'de':(3, u'Deutsch'),
33        'ha':(4, u'Hausa'),
34        'yo':(5, u'Yoruba'),
35        'ig':(6, u'Igbo'),
36        }
37
38    EXAM_SUBJECTS_DICT = {
39        'accounts': 'Accounts',
40        'add_general_science': 'Add General Science',
41        'add_maths': 'Add Maths',
42        'agricultural_science': 'Agricultural Science',
43        'applied_electricity': 'Applied Electricity',
44        'arabi': 'Arabic',
45        'arithmetics': 'Arithmetics',
46        'art': 'Art',
47        'auto_mechanics': 'Auto Mechanics',
48        'basic_electricity': 'Basic Electricity',
49        'bible_knowledge': 'Bible Knowledge',
50        'biology': 'Biology',
51        'biology_alt_syl': 'Biology (Alt.Syl)',
52        'book_keeping': 'Book Keeping',
53        'building_construction': 'Building Construction',
54        'business_management': 'Business Management',
55        'business_construction_management': 'Business/Construction Management (Adv)',
56        'chemistry': 'Chemistry',
57        'chemistry_alt_syl': 'Chemistry (Alt.Syl)',
58        'christian_religious_studies': 'Christian Religious Studies',
59        'clerical_office_duties': 'Clerical Office Duties',
60        'clothing_and_textiles': 'Clothing and Textiles',
61        'commerce': 'Commerce',
62        'economics': 'Economics',
63        'education': 'Education',
64        'efik': 'Efik',
65        'electronics': 'Electronics',
66        'elementary_surveying': 'Elementary Surveying',
67        'english_language': 'English Language',
68        'engineering_science': 'Engineering Science',
69        'financial_accounting': 'Financial Accounting',
70        'food_and_nutrition': 'Food and Nutrition',
71        'french': 'French',
72        'further_mathematics': 'Further Mathematics',
73        'general_science': 'General Science',
74        'geography': 'Geography',
75        'german': 'German',
76        'government': 'Government',
77        'hausa': 'Hausa',
78        'hausa_literature': 'Hausa Literature',
79        'health_science': 'Health Science',
80        'history': 'History',
81        'home_management': 'Home Management',
82        'industrial_electrical_installation': 'Industrial Elect Installation (Adv)',
83        'intergrated_science': 'Intergrated Science',
84        'islamic_studies': 'Islamic Studies',
85        'literature_in_english': 'Literature in English',
86        'literature_in_nigerian_languages': 'Literature in Nigerian Languages',
87        'igbo': 'Igbo',
88        'igbo_literature': 'Igbo Literature',
89        'yoruba': 'Yoruba',
90        'yoruba_literature': 'Yoruba Literature',
91        'management_in_living': 'Management in Living',
92        'mathematics': 'Mathematics',
93        'metalwork': 'Metalwork',
94        'music': 'Music',
95        'nigerian_language': 'Nigerian Language',
96        'office_practice': 'Office Practice',
97        'physical_education': 'Physical Education',
98        'physical_health_education': 'Physical and Health Education',
99        'physics': 'Physics',
100        'physics_alt_syl': 'Physics (Alt.Syl)',
101        'principles_of_cost_accounting': 'Principles of Cost Accounting',
102        'rural_science': 'Rural Science',
103        'science': 'Science',
104        'secretarial_duties': 'Secretarial Duties',
105        'shorthand': 'Shorthand',
106        'sierra_leone_studies': 'Sierra Leone Studies',
107        'sierra_leone_languages': 'Sierra Leone Languages',
108        'social_studies': 'Social Studies',
109        'statistics': 'Statistics',
110        'teaching_practice': 'Teaching Practice',
111        'technical_drawing': 'Technical Drawing',
112        'typewriting': 'Typewriting',
113        'visual_art': 'Visual Art',
114        'woodwork': 'Woodwork',
115        'winding_elect_machines': 'Winding of Elect Machines and Elect Eng Sc'
116        }
117
118    EXAM_GRADES_DICT = {
119        'A1': (1, 'Excellent (A1)'),
120        'A2': (2, 'Very Good (A2)'),
121        'A3': (3, 'Good (A3)'),
122        'B2': (4, 'Very Good (B2)'),
123        'B3': (5, 'Good (B3)'),
124        'C4': (6, 'Credit (C4)'),
125        'C5': (7, 'Credit (C5)'),
126        'C6': (8, 'Credit (C6)'),
127        'D7': (9, 'Pass (D7)'),
128        'E8': (10, 'Pass (E8)'),
129        'F9': (11, 'Fail (F9)'),
130        'Aa': (12, 'A (a)'),
131        'Bb': (13, 'B (b)'),
132        'Cc': (14, 'C (c)'),
133        'Dd': (15, 'D (d)'),
134        'Ee': (16, 'E (e)'),
135        'Ff': (17, 'F (f)'),
136        'Gg': (18, 'G (g)')
137        }
138
139    INST_TYPES_DICT = {
140        'faculty': 'Faculty of',
141        'department': 'Department of',
142        'school': 'School of',
143        'office': 'Office for',
144        'centre': 'Centre for',
145        'institute': 'Institute of',
146        'school_for': 'School for',
147        }
148
149    STUDY_MODES_DICT = {
150        'rmd_ft': 'Remedial with deficiencies',
151        'dp_pt': 'Diploma Part Time',
152        'ct_ft': 'Certificate Full Time',
153        'dp_ft': 'Diploma Full Time',
154        'de_pt': 'Direct Entry Part Time',
155        'pg_ft': 'Postgraduate Full Time',
156        'pg_pt': 'Postgraduate Part Time',
157        'jm_ft': 'Joint Matriculation Full Time',
158        'ume_ft': 'UME Full Time',
159        'de_ft': 'Direct Entry Full Time',
160        'ph_ft': 'Post Higher Education Full Time',
161        'transfer_pt': 'Transfer Part Time',
162        'ug_pt': 'Undergraduate Part Time',
163        'transfer_ft': 'Transfer Full Time',
164        'ct_pt': 'Certificate Part Time',
165        'ug_ft': 'Undergraduate Full Time',
166        'rm_ft': 'Remedial'
167        }
168
169    APP_CATS_DICT = {
170        'basic': 'PUME, PDE, PCE, PRENCE',
171        'no': 'no application',
172        'pg': 'Postgraduate',
173        'sandwich': 'Sandwich',
174        'cest': 'Part-Time, Diploma, Certificate'
175        }
Note: See TracBrowser for help on using the repository browser.