Ignore:
Timestamp:
15 Feb 2022, 17:42:22 (3 years ago)
Author:
Henrik Bettermann
Message:

Change flc application form.

Location:
main/waeup.uniben/trunk/src/waeup/uniben
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • main/waeup.uniben/trunk/src/waeup/uniben/applicants/browser.py

    r16804 r16807  
    258258            #form_fields['perm_address'].custom_widget = BytesDisplayWidget
    259259            return form_fields
    260         if self.target is not None and self.target == 'french':
     260        if self.target is not None and self.target == 'flc':
    261261            form_fields = grok.AutoFields(IFrenchApplicant)
    262262            for field in REGISTRATION_OMIT_DISPLAY_FIELDS:
     
    458458                form_fields['registration_cats'].for_display = True
    459459            return form_fields
    460         if self.target is not None and self.target == 'french':
     460        if self.target is not None and self.target == 'flc':
    461461            form_fields = grok.AutoFields(IFrenchApplicant)
    462462            for field in REGISTRATION_OMIT_MANAGE_FIELDS:
     
    543543                form_fields['registration_cats'].for_display = True
    544544            return form_fields
    545         if self.target is not None and self.target == 'french':
     545        if self.target is not None and self.target == 'flc':
    546546            form_fields = grok.AutoFields(IFrenchApplicant)
    547547            for field in REGISTRATION_OMIT_EDIT_FIELDS:
     
    721721                for field in PUDE_OMIT_PDF_FIELDS:
    722722                    form_fields = form_fields.omit(field)
    723         elif self.target is not None and self.target == 'french':
     723        elif self.target is not None and self.target == 'flc':
    724724            form_fields = grok.AutoFields(IFrenchApplicant)
    725725            for field in REGISTRATION_OMIT_PDF_FIELDS:
  • main/waeup.uniben/trunk/src/waeup/uniben/applicants/interfaces.py

    r16804 r16807  
    146146    """
    147147    def getValues(self):
    148         return ['n', 'c', 'p']
     148        return ['c', 'p']
    149149
    150150    def getToken(self, value):
     
    152152
    153153    def getTitle(self, value):
    154         if value == 'n':
    155             return _('none')
     154        #if value == 'n':
     155        #    return _('none')
    156156        if value == 'c':
    157157            return _('conversational')
    158         if value == 'c':
     158        if value == 'p':
    159159            return _('professional')
     160
     161class PreferredSessionSource(BasicSourceFactory):
     162    """
     163    """
     164    def getValues(self):
     165        return ['m', 'e', 'w']
     166
     167    def getToken(self, value):
     168        return value
     169
     170    def getTitle(self, value):
     171        if value == 'm':
     172            return _('morning')
     173        if value == 'e':
     174            return _('evening')
     175        if value == 'w':
     176            return _('weekend')
    160177
    161178class IUnibenRegistration(IKofaObject):
     
    547564        show_year = True,
    548565        )
     566
     567    pref_session = schema.Choice(
     568        source = PreferredSessionSource(),
     569        title = _(u'Preferred Session'),
     570        required = False,
     571        )
     572
    549573    proficiency = schema.Choice(
    550574        source = ProficiencySource(),
  • main/waeup.uniben/trunk/src/waeup/uniben/applicants/utils.py

    r16804 r16807  
    6868        'tscf': ['Transcript (without student record)', 'TRF'],
    6969        'tscs': ['Transcript (with student record)', 'TRS'],
    70         'french': ['French Language Centre', 'FR'],
     70        'flc': ['French Language Centre', 'FR'],
    7171        }
    7272
  • main/waeup.uniben/trunk/src/waeup/uniben/utils/utils.py

    r16780 r16807  
    5757        'special_ft': 'Special Full-Time',
    5858        'cdl': 'Center For Distance Learning',
     59        'french': 'French Language Center',
    5960        }
    6061
Note: See TracChangeset for help on using the changeset viewer.