Ignore:
Timestamp:
8 Jan 2013, 07:52:55 (12 years ago)
Author:
Henrik Bettermann
Message:

Implement local student data exports in certificates.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • main/waeup.kofa/trunk/src/waeup/kofa/university/certificate.py

    r9826 r9842  
    1919"""
    2020import grok
     21import zope.location.location
    2122from zope.event import notify
    2223from zope.catalog.interfaces import ICatalog
     
    3031    ICertificate, ICertificateAdd, ICertificateCourse)
    3132from waeup.kofa.university.vocabularies import course_levels
     33from waeup.kofa.utils.batching import VirtualExportJobContainer
     34
     35class VirtualCertificateExportJobContainer(VirtualExportJobContainer):
     36    """A virtual export job container for certificates.
     37    """
    3238
    3339class Certificate(grok.Container):
     
    6167        self.school_fee_3 = school_fee_3
    6268        self.school_fee_4 = school_fee_4
     69
     70    def traverse(self, name):
     71        """Deliver appropriate containers.
     72        """
     73        if name == 'exports':
     74            # create a virtual exports container and return it
     75            container = VirtualCertificateExportJobContainer()
     76            zope.location.location.located(container, self, 'exports')
     77            return container
     78        return None
    6379
    6480    def longtitle(self):
Note: See TracChangeset for help on using the changeset viewer.