Ignore:
Timestamp:
1 Dec 2022, 15:57:05 (2 years ago)
Author:
Henrik Bettermann
Message:

Finetune exporter pages.

Location:
main/kofacustom.lpng/trunk/src/kofacustom/lpng/browser
Files:
2 added
1 edited

Legend:

Unmodified
Added
Removed
  • main/kofacustom.lpng/trunk/src/kofacustom/lpng/browser/pages.py

    r16993 r17201  
    1717##
    1818import grok
    19 from waeup.kofa.interfaces import IKofaUtils, IKofaObject
     19from zope.component import (
     20    getUtility, queryUtility, createObject, getAllUtilitiesRegisteredFor,
     21    getUtilitiesFor,
     22    )
     23from waeup.kofa.interfaces import IKofaUtils, IKofaObject, ICSVExporter
    2024from waeup.kofa.browser.pages import (
    2125    SessionConfigurationAddFormPage, SessionConfigurationManageFormPage,
    22     LoginPage, CertificatePage, CertificateManageFormPage)
     26    LoginPage, CertificatePage, CertificateManageFormPage,
     27    ExportCSVPage)
    2328from waeup.kofa.university.interfaces import ICertificate
    2429from kofacustom.lpng.interfaces import (
    2530    ICustomSessionConfiguration, ICustomSessionConfigurationAdd)
     31
     32grok.templatedir('templates')
    2633
    2734class CustomSessionConfigurationAddFormPage(SessionConfigurationAddFormPage):
     
    3542    form_fields = grok.AutoFields(ICustomSessionConfiguration)
    3643
     44class CustomExportCSVPage(ExportCSVPage):
     45
     46    grok.template('datacenterexportpage')
     47
     48    def getExporters(self):
     49        title_name_tuples = [
     50            (u'Registrants', u'applicants'),
     51            (u'Registrant Payments', u'applicantpayments'),
     52            (u'Registrants Containers', u'applicantscontainers'),
     53            (u'Users', u'users'),
     54            ]
     55        return sorted(title_name_tuples)
Note: See TracChangeset for help on using the changeset viewer.