Ignore:
Timestamp:
5 Jul 2015, 15:10:20 (9 years ago)
Author:
Henrik Bettermann
Message:

Enable pre-studies (JUPEB) application (Uniben).

Extend pg application form.

Location:
main/kofacustom.nigeria/trunk/src/kofacustom/nigeria/applicants
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • main/kofacustom.nigeria/trunk/src/kofacustom/nigeria/applicants/browser.py

    r10898 r13140  
    8686            for field in PG_OMIT_DISPLAY_FIELDS:
    8787                form_fields = form_fields.omit(field)
     88        # Don't know what pre-degree studies are, seems to be pre-postgraduate.
     89        # Many modifications are expected. Therefore, we need a dedicated
     90        # elif statement (see also pages below)
     91        elif self.target is not None and self.target.startswith('pre'):
     92            form_fields = grok.AutoFields(INigeriaPGApplicant)
     93            for field in PG_OMIT_DISPLAY_FIELDS:
     94                form_fields = form_fields.omit(field)
    8895        elif self.target is not None and self.target.startswith('putme'):
    8996            form_fields = grok.AutoFields(INigeriaUGApplicant)
     
    127134            for field in PG_OMIT_PDF_FIELDS:
    128135                form_fields = form_fields.omit(field)
     136        elif self.target is not None and self.target.startswith('pre'):
     137            form_fields = grok.AutoFields(INigeriaPGApplicant)
     138            for field in PG_OMIT_PDF_FIELDS:
     139                form_fields = form_fields.omit(field)
    129140        elif self.target is not None and self.target.startswith('putme'):
    130141            form_fields = grok.AutoFields(INigeriaUGApplicant)
     
    167178            for field in PG_OMIT_MANAGE_FIELDS:
    168179                form_fields = form_fields.omit(field)
     180        elif self.target is not None and self.target.startswith('pre'):
     181            form_fields = grok.AutoFields(INigeriaPGApplicant)
     182            for field in PG_OMIT_MANAGE_FIELDS:
     183                form_fields = form_fields.omit(field)
    169184        elif self.target is not None and self.target.startswith('putme'):
    170185            form_fields = grok.AutoFields(INigeriaUGApplicant)
     
    191206        if self.target is not None and self.target.startswith('pg'):
    192207            form_fields = grok.AutoFields(INigeriaPGApplicantEdit)
     208            for field in PG_OMIT_EDIT_FIELDS:
     209                form_fields = form_fields.omit(field)
     210        elif self.target is not None and self.target.startswith('pre'):
     211            form_fields = grok.AutoFields(INigeriaPGApplicant)
    193212            for field in PG_OMIT_EDIT_FIELDS:
    194213                form_fields = form_fields.omit(field)
  • main/kofacustom.nigeria/trunk/src/kofacustom/nigeria/applicants/interfaces.py

    r11810 r13140  
    280280        readonly = False,
    281281        )
    282     pp_school = schema.Choice(
    283         title = _(u'Qualification Obtained'),
     282    fst_sit_fname = schema.TextLine(
     283        title = _(u'Full Name'),
     284        required = False,
     285        readonly = False,
     286        )
     287    fst_sit_no = schema.TextLine(
     288        title = _(u'Exam Number'),
     289        required = False,
     290        readonly = False,
     291        )
     292    fst_sit_date = FormattedDate(
     293        title = _(u'Exam Date'),
     294        required = False,
     295        readonly = False,
     296        show_year = True,
     297        )
     298    fst_sit_type = schema.Choice(
     299        title = _(u'Exam Type'),
    284300        required = False,
    285301        readonly = False,
    286302        vocabulary = exam_types,
    287303        )
     304    fst_sit_results = schema.List(
     305        title = _(u'Exam Results'),
     306        value_type = ResultEntryField(),
     307        required = False,
     308        readonly = False,
     309        default = [],
     310        )
     311    scd_sit_fname = schema.TextLine(
     312        title = _(u'Full Name'),
     313        required = False,
     314        readonly = False,
     315        )
     316    scd_sit_no = schema.TextLine(
     317        title = _(u'Exam Number'),
     318        required = False,
     319        readonly = False,
     320        )
     321    scd_sit_date = FormattedDate(
     322        title = _(u'Exam Date'),
     323        required = False,
     324        readonly = False,
     325        show_year = True,
     326        )
     327    scd_sit_type = schema.Choice(
     328        title = _(u'Exam Type'),
     329        required = False,
     330        readonly = False,
     331        vocabulary = exam_types,
     332        )
     333    scd_sit_results = schema.List(
     334        title = _(u'Exam Results'),
     335        value_type = ResultEntryField(),
     336        required = False,
     337        readonly = False,
     338        default = [],
     339        )
     340    # Replaced by first and second sitting
     341    #pp_school = schema.Choice(
     342    #    title = _(u'Qualification Obtained'),
     343    #    required = False,
     344    #    readonly = False,
     345    #    vocabulary = exam_types,
     346    #    )
    288347    presently_inst = schema.TextLine(
    289348        title = _(u'If yes, name of institution'),
  • main/kofacustom.nigeria/trunk/src/kofacustom/nigeria/applicants/utils.py

    r9634 r13140  
    5454        'form.pp_school': _(u'Post Primary School Qualification'),
    5555        'form.presently_inst': _(u'Presently attending a course or programme'),
     56        'form.fst_sit_fname': _(u'First Sitting Record'),
     57        'form.scd_sit_fname': _(u'Second Sitting Record'),
    5658        }
Note: See TracChangeset for help on using the changeset viewer.