- Timestamp:
- 14 Jun 2012, 08:51:01 (13 years ago)
- Location:
- main/waeup.kofa/trunk/src/waeup/kofa/applicants
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
main/waeup.kofa/trunk/src/waeup/kofa/applicants/export.py
r8381 r8724 21 21 from zope.catalog.interfaces import ICatalog 22 22 from zope.component import queryUtility 23 from waeup.kofa.applicants.interfaces import IApplicantBaseData 23 from waeup.kofa.applicants.interfaces import ( 24 IApplicantBaseData, IApplicantsContainer) 24 25 from waeup.kofa.interfaces import ICSVExporter 25 26 from waeup.kofa.interfaces import MessageFactory as _ 26 27 from waeup.kofa.utils.batching import ExporterBase 28 from waeup.kofa.utils.helpers import iface_names 27 29 28 30 class ApplicantsContainerExporter(grok.GlobalUtility, ExporterBase): … … 33 35 34 36 #: Fieldnames considered by this exporter 35 fields = ('code', 'title', 'prefix', 'year', 36 'application_category', 'description', 37 'startdate', 'enddate', 'strict_deadline') 38 37 fields = tuple(sorted(iface_names(IApplicantsContainer))) 39 38 #: The title under which this exporter will be displayed 40 39 title = _(u'Basic Applicants Containers') -
main/waeup.kofa/trunk/src/waeup/kofa/applicants/tests/test_export.py
r8377 r8724 6 6 import unittest 7 7 from zope.catalog.interfaces import ICatalog 8 from zope.component import queryUtility, getUtility , getUtilitiesFor8 from zope.component import queryUtility, getUtility 9 9 from zope.interface.verify import verifyObject, verifyClass 10 10 from zope.intid.interfaces import IIntIds … … 71 71 self.assertEqual( 72 72 result, 73 ' code,title,prefix,year,application_category,'74 ' description,startdate,enddate,strict_deadline\r\n'75 76 ' dp2012,General Studies 2012/13,app,2012,basic,'73 'application_category,application_fee,code,description,' 74 'enddate,mode,prefix,startdate,strict_deadline,title,year\r\n' 75 76 'basic,0.0,dp2012,' 77 77 '"Some Description\nwith linebreak\n<<de>>man spriht deutsh",' 78 '2012-01-01 12:00:00+00:00,2012-01-31 23:00:00+00:00,1\r\n' 78 '2012-01-31 23:00:00+00:00,,app,2012-01-01 12:00:00+00:00,1,' 79 'General Studies 2012/13,2012\r\n' 79 80 ) 80 81 return
Note: See TracChangeset for help on using the changeset viewer.