Ignore:
Timestamp:
16 Dec 2015, 06:07:20 (9 years ago)
Author:
Henrik Bettermann
Message:

Use new ITranscriptApplicant interface for application.

Adjust importer and exporter.

File:
1 edited

Legend:

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

    r13541 r13544  
    2626from waeup.kofa.utils.helpers import string_from_bytes, file_size
    2727from waeup.kofa.applicants.browser import ApplicantCheckStatusPage
    28 from waeup.kofa.applicants.interfaces import ISpecialApplicant
    2928from waeup.kofa.applicants.viewlets import PDFActionButton
    3029from waeup.aaue.interfaces import MessageFactory as _
     
    4140    UG_OMIT_EDIT_FIELDS)
    4241from waeup.aaue.applicants.interfaces import (
    43     ICustomApplicant,
    4442    ICustomUGApplicant,
    45     ICustomUGApplicantEdit
     43    ICustomUGApplicantEdit,
     44    ITranscriptApplicant
    4645    )
    4746
     
    7170    def form_fields(self):
    7271        if self.target is not None and self.target == 'trans':
    73             return grok.AutoFields(ISpecialApplicant).omit(
    74                 'locked', 'suspended', 'special_application')
     72            form_fields = grok.AutoFields(ITranscriptApplicant).omit(
     73                'locked', 'suspended')
     74            form_fields['dispatch_address'].custom_widget = BytesDisplayWidget
     75            form_fields['perm_address'].custom_widget = BytesDisplayWidget
     76            return form_fields
    7577        # AAUE is using the same interface for all regular applications.
    7678        form_fields = grok.AutoFields(ICustomUGApplicant)
     
    160162    def form_fields(self):
    161163        if self.target is not None and self.target == 'trans':
    162             form_fields = grok.AutoFields(ISpecialApplicant).omit(
    163                 'special_application')
     164            form_fields = grok.AutoFields(ITranscriptApplicant)
    164165            form_fields['applicant_id'].for_display = True
    165166            return form_fields
     
    188189    def form_fields(self):
    189190        if self.target is not None and self.target == 'trans':
    190             form_fields = grok.AutoFields(ISpecialApplicant).omit(
    191                 'locked', 'suspended', 'special_application')
     191            form_fields = grok.AutoFields(ITranscriptApplicant).omit(
     192                'locked', 'suspended')
    192193            form_fields['applicant_id'].for_display = True
    193194            return form_fields
Note: See TracChangeset for help on using the changeset viewer.