Changeset 7788 for main/waeup.sirp
- Timestamp:
- 7 Mar 2012, 23:14:52 (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
main/waeup.sirp/branches/ulif-schoolgrades/src/waeup/sirp/schema/field.py
r7765 r7788 19 19 """ 20 20 from zope.interface import implements 21 from zope.schema import TextLine , Object21 from zope.schema import TextLine 22 22 from zope.schema.interfaces import ( 23 23 ITextLine, IBaseVocabulary, ISource, IContextSourceBinder, InvalidValue,) 24 24 from zope.schema.vocabulary import ( 25 25 SimpleVocabulary, getVocabularyRegistry, VocabularyRegistryError) 26 from waeup.sirp.schema.interfaces import IMultiValObject27 26 28 27 class CustomizableErrorMsg(object): … … 126 125 raise InvalidValue(value) 127 126 return 128 129 class MultiValObject(Object):130 """A zope.schema.Object-like field for content types with several values.131 132 You can use it like this in interface definitions::133 134 myattr = MultiValObject(135 schema = IMyComplexType136 )137 138 See :mod:`zope.schema` for further infos about `Object`.139 140 As multi-value objects should normally be rendered different in141 forms than single value objects, we need a different schema142 definition for these.143 144 In waeup.sirp we also provide widgets that render MultiValObjects145 automatically.146 """147 implements(IMultiValObject)
Note: See TracChangeset for help on using the changeset viewer.