- Timestamp:
- 16 May 2011, 14:07:54 (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
main/waeup.sirp/trunk/src/waeup/sirp/applicants/applicants.py
r6114 r6115 21 21 ## 22 22 import grok 23 from grok import index 23 24 from zope.component.interfaces import IFactory 24 25 from zope.interface import implementedBy 25 26 from zope.schema.fieldproperty import FieldProperty 26 27 from waeup.sirp.interfaces import IWAeUPSIRPPluggable 28 from waeup.sirp.app import University 27 29 from waeup.sirp.applicants.interfaces import ( 28 30 IResultEntry, IApplicant, IApplicantPDEEditData, 29 31 DEFAULT_PASSPORT_IMAGE_MALE, 30 32 ) 31 from waeup.sirp.utils.helpers import attr _to_fields33 from waeup.sirp.utils.helpers import attrs_to_fields 32 34 33 35 class ResultEntry(grok.Context): … … 46 48 # ourselves and as a bonus we get free validation when an attribute is 47 49 # set. 48 Applicant = attr_to_fields(Applicant) 50 Applicant = attrs_to_fields(Applicant) 51 52 class ApplicantCatalog(grok.Indexes): 53 """A catalog indexing :class:`Applicant` instances in the ZODB. 54 """ 55 grok.site(University) 56 grok.name('applicants_catalog') 57 grok.context(IApplicant) 58 59 access_code = index.Field(attribute='access_code') 60 49 61 50 62 class ApplicantTraverser(grok.Traverser):
Note: See TracChangeset for help on using the changeset viewer.