- Timestamp:
- 23 Sep 2016, 05:54:20 (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
main/ikobacustom.uniben/trunk/src/ikobacustom/uniben/documents/document.py
r14178 r14181 24 24 from waeup.ikoba.utils.helpers import attrs_to_fields 25 25 from waeup.ikoba.documents.document import PublicDocumentBase 26 from ikobacustom.uniben.documents.interfaces import I SkeletonDocument26 from ikobacustom.uniben.documents.interfaces import IUnibenDocument 27 27 from ikobacustom.uniben.interfaces import MessageFactory as _ 28 28 29 29 30 class SkeletonDocument(PublicDocumentBase):30 class UnibenDocument(PublicDocumentBase): 31 31 """This is a document. 32 32 """ 33 grok.implements(I SkeletonDocument)34 grok.provides(I SkeletonDocument)33 grok.implements(IUnibenDocument) 34 grok.provides(IUnibenDocument) 35 35 36 form_fields_interface = I SkeletonDocument36 form_fields_interface = IUnibenDocument 37 37 38 SkeletonDocument = attrs_to_fields(SkeletonDocument)38 UnibenDocument = attrs_to_fields(UnibenDocument) 39 39 40 40 41 class SkeletonDocumentFactory(grok.GlobalUtility):41 class UnibenDocumentFactory(grok.GlobalUtility): 42 42 """A factory for documents. 43 43 """ 44 44 grok.implements(IFactory) 45 grok.name(u'waeup. SkeletonDocument')45 grok.name(u'waeup.UnibenDocument') 46 46 title = u"Create a new document.", 47 47 description = u"This factory instantiates new uniben documents." 48 48 49 49 def __call__(self, *args, **kw): 50 return SkeletonDocument(*args, **kw)50 return UnibenDocument(*args, **kw) 51 51 52 52 def getInterfaces(self): 53 return implementedBy( SkeletonDocument)53 return implementedBy(UnibenDocument)
Note: See TracChangeset for help on using the changeset viewer.