Author: jmorliaguet
Date: Tue Oct 25 18:36:02 2005
New Revision: 28632

Modified:
   z3lab/z3ecm/trunk/src/ecm/cpsskins/example1/README.txt
   z3lab/z3ecm/trunk/src/ecm/cpsskins/example1/hello.py
   z3lab/z3ecm/trunk/src/ecm/cpsskins/example2/text.py
   z3lab/z3ecm/trunk/src/ecm/cpsskins/example3/items.py
   z3lab/z3ecm/trunk/src/ecm/cpsskins/example4/actions.py
Log:

- portlets only need to subclass persistent.Persistent



Modified: z3lab/z3ecm/trunk/src/ecm/cpsskins/example1/README.txt
==============================================================================
--- z3lab/z3ecm/trunk/src/ecm/cpsskins/example1/README.txt      (original)
+++ z3lab/z3ecm/trunk/src/ecm/cpsskins/example1/README.txt      Tue Oct 25 
18:36:02 2005
@@ -19,7 +19,6 @@
 
 Let us set up some test environment:
 
-    >>> from zope.component import adapts
     >>> from zope.interface import implements
 
 
@@ -58,7 +57,7 @@
 Now that you have an interface definition for your portlet you need to create
 a class that implements the interface.
 
-Make your portlet a persistent object [NB: not implemented yet]
+Make your portlet a persistent object.
 
     >>> from persistent import Persistent
 

Modified: z3lab/z3ecm/trunk/src/ecm/cpsskins/example1/hello.py
==============================================================================
--- z3lab/z3ecm/trunk/src/ecm/cpsskins/example1/hello.py        (original)
+++ z3lab/z3ecm/trunk/src/ecm/cpsskins/example1/hello.py        Tue Oct 25 
18:36:02 2005
@@ -17,16 +17,15 @@
 """
 __docformat__ = "reStructuredText"
 
-from zope.component import adapts
+from persistent import Persistent
 from zope.interface import implements
 
-from cpsskins import Portlet
 from cpsskins.interfaces import IPortlet
 
 class IHelloPortlet(IPortlet):
     """Interface for the 'hello world' portlet"""
 
-class HelloPortlet(Portlet):
+class HelloPortlet(Persistent):
     """The Hello portlet always says 'Hello world'.
 
     It is not configurable.

Modified: z3lab/z3ecm/trunk/src/ecm/cpsskins/example2/text.py
==============================================================================
--- z3lab/z3ecm/trunk/src/ecm/cpsskins/example2/text.py (original)
+++ z3lab/z3ecm/trunk/src/ecm/cpsskins/example2/text.py Tue Oct 25 18:36:02 2005
@@ -17,11 +17,10 @@
 """
 __docformat__ = "reStructuredText"
 
-from zope.component import adapts
+from persistent import Persistent
 from zope.interface import implements
 from zope.schema import Text
 
-from cpsskins import Portlet
 from cpsskins.interfaces import IPortlet
 
 class ITextPortlet(IPortlet):
@@ -29,7 +28,7 @@
     """
     text = Text(title=u"Some text")
 
-class TextPortlet(Portlet):
+class TextPortlet(Persistent):
     """The Text portlet displays some text entered by the user.
     """
     implements(ITextPortlet)

Modified: z3lab/z3ecm/trunk/src/ecm/cpsskins/example3/items.py
==============================================================================
--- z3lab/z3ecm/trunk/src/ecm/cpsskins/example3/items.py        (original)
+++ z3lab/z3ecm/trunk/src/ecm/cpsskins/example3/items.py        Tue Oct 25 
18:36:02 2005
@@ -17,10 +17,9 @@
 """
 __docformat__ = "reStructuredText"
 
-from zope.component import adapts
+from persistent import Persistent
 from zope.interface import implements
 
-from cpsskins import Portlet
 from cpsskins.interfaces import IPortlet
 from cpsskins.model import Items, Item
 
@@ -28,7 +27,7 @@
     """Interface for the Items portlet.
     """
 
-class ItemsPortlet(Portlet):
+class ItemsPortlet(Persistent):
     """The Items portlet returns a list of items.
     """
     implements(IItemsPortlet)

Modified: z3lab/z3ecm/trunk/src/ecm/cpsskins/example4/actions.py
==============================================================================
--- z3lab/z3ecm/trunk/src/ecm/cpsskins/example4/actions.py      (original)
+++ z3lab/z3ecm/trunk/src/ecm/cpsskins/example4/actions.py      Tue Oct 25 
18:36:02 2005
@@ -17,8 +17,8 @@
 """
 __docformat__ = "reStructuredText"
 
+from persistent import Persistent
 from zope.app.publisher.browser.menu import getMenu
-from zope.component import adapts
 from zope.component.exceptions import ComponentLookupError
 from zope.interface import implements
 from zope.schema import TextLine
@@ -36,7 +36,7 @@
         title=u"Category",
         )
 
-class ActionsPortlet(Portlet):
+class ActionsPortlet(Persistent):
     """The actions portlet returns a list of items.
     """
     implements(IActionsPortlet)
-- 
http://lists.nuxeo.com/mailman/listinfo/z3lab-checkins

Reply via email to