- Timestamp:
- 14 May 2011, 14:19:59 (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
main/waeup.sirp/trunk/src/waeup/sirp/applicants/interfaces.py
r6076 r6087 5 5 ## $Id$ 6 6 ## 7 ## Copyright (C) 2011 Uli Fouquet 7 ## Copyright (C) 2011 Uli Fouquet & Henrik Bettermann 8 8 ## This program is free software; you can redistribute it and/or modify 9 9 ## it under the terms of the GNU General Public License as published by … … 34 34 from waeup.sirp.image.image import WAeUPImageFile 35 35 from waeup.sirp.interfaces import IWAeUPObject, SimpleWAeUPVocabulary 36 from waeup.sirp.university.vocabularies import FutureYearsSource 36 37 37 38 … … 49 50 ) 50 51 51 #: Categories of applications we support. 52 #: Yet not complete nor correct. 53 APPLICATION_CATEGORIES = ( 54 ('Direct Entry Screening Exam (PDE)', 'pde'), 55 ('Post-UME', 'pume'), 56 ('Post-UDE', 'pude'), 57 ('PCE', 'pce'), 52 #: Types of applications we support. 53 APPLICATION_TYPES = ( 54 ('Pre-NCE Programme', 'prence'), 55 ('Post UME Screening Test', 'pume'), 56 ('Post UDE Screening', 'pude'), 57 ('Part Time Degree in Education', 'sandwich'), 58 ('Part-Time Degree Programmes', 'pt'), 59 ('Diploma Programmes', 'dp'), 60 ('PCE Screening', 'pce'), 61 ('Certificate Programmes', 'ct'), 58 62 ('Common Entry Screening Test (CEST)', 'cest'), 59 63 ) 60 64 61 65 #: A :class:`waeup.sirp.interfaces.SimpleWAeUPVocabulary` of supported 62 #: application categories.63 application_ categories_vocab = SimpleWAeUPVocabulary(*APPLICATION_CATEGORIES)66 #: application or screening types. 67 application_types_vocab = SimpleWAeUPVocabulary(*APPLICATION_TYPES) 64 68 65 69 class GenderSource(BasicSourceFactory): … … 152 156 code = schema.TextLine( 153 157 title = u'Code', 154 description = u'Abbreviated code of applicants container', 155 default = u'NA', 156 required = True, 157 readonly = True, 158 ) 158 default = u'-', 159 required = True, 160 readonly = True, 161 ) 162 163 title = schema.TextLine( 164 title = u'Title', 165 required = True, 166 default = u'-', 167 readonly = True, 168 ) 169 170 prefix = schema.Choice( 171 title = u'Application target', 172 required = True, 173 default = None, 174 source = application_types_vocab, 175 readonly = True, 176 ) 177 178 year = schema.Choice( 179 title = u'Year of entrance', 180 required = True, 181 default = None, 182 source = FutureYearsSource(), 183 readonly = True, 184 ) 159 185 160 186 provider = schema.Choice( … … 163 189 default = None, 164 190 source = ApplicantContainerProviderSource(), 165 ) 166 167 title = schema.TextLine( 168 title = u'Title of the type of applicants stored here', 169 required = True, 170 default = u'Untitled', 191 readonly = True, 171 192 ) 172 193 … … 228 249 """An applicants container contains university applicants. 229 250 """ 230 code = schema.TextLine(231 title = u' Code',232 description = u'Abbreviated code of applicants container',233 default = u'NA',234 required = True,251 prefix = schema.Choice( 252 title = u'Application target', 253 required = True, 254 default = None, 255 source = application_types_vocab, 235 256 readonly = False, 236 257 ) 237 258 238 IApplicantsContainerAdd['code'].order = IApplicantsContainer['code'].order 259 year = schema.Choice( 260 title = u'Year of entrance', 261 required = True, 262 default = None, 263 source = FutureYearsSource(), 264 readonly = False, 265 ) 266 267 provider = schema.Choice( 268 title = u'Applicants container type', 269 required = True, 270 default = None, 271 source = ApplicantContainerProviderSource(), 272 readonly = False, 273 ) 274 275 IApplicantsContainerAdd['prefix'].order = IApplicantsContainer['prefix'].order 276 IApplicantsContainerAdd['year'].order = IApplicantsContainer['year'].order 277 IApplicantsContainerAdd['provider'].order = IApplicantsContainer['provider'].order 239 278 240 279 class IApplicantBaseData(IWAeUPObject):
Note: See TracChangeset for help on using the changeset viewer.