jmf wrote:
Le vendredi 08 janvier 2010 11:11:34 AM, Graham Perrin a écrit :
Graham Perrin wrote:
Please: any suggestions on how to make collective.contentlicensing
compatible with Plone 4?


Hi folks,

looking at

  http://dev.plone.org/collective/browser/collective.contentlicensing

it seems like people are working on it.

Since this product is on my watch list anyway, I just gave it a try.
Starting from

http://svn.plone.org/svn/collective/collective.contentlicensing/branches/davisagli-sanity-and-modernization

I got it up and running on Plone 4 (a3) after the following changes:

Index: collective/contentlicensing/browser/configure.zcml
===================================================================
--- collective/contentlicensing/browser/configure.zcml  (revision 108301)
+++ collective/contentlicensing/browser/configure.zcml  (working copy)
@@ -105,8 +105,5 @@
      layer="..interfaces.IContentLicensingLayer"
      />

-  <five:traversable class="OFS.Application.Application" />
-
- <five:traversable class="Products.CMFCore.PortalObject.PortalObjectBase" />

 </configure>
Index: collective/contentlicensing/setupHandlers.py
===================================================================
--- collective/contentlicensing/setupHandlers.py        (revision 108301)
+++ collective/contentlicensing/setupHandlers.py        (working copy)
@@ -22,7 +22,7 @@
 __version__ = "$Revision: 1 $"[11:-2]

 from zope.app.component.interfaces import ISite
-from Products.Five.site.localsite import enableLocalSiteHook
+from five.localsitemanager import make_objectmanager_site
 from zope.app.component.hooks import setSite
 from utilities.interfaces import IContentLicensingUtility
 from utilities.utils import ContentLicensingUtility
@@ -37,7 +37,7 @@
     """ Register a local utility """

     if not ISite.providedBy(site):
-        enableLocalSiteHook(site)
+        make_objectmanager_site(site)

     setSite(site)


I'm hesitant to check that in as it breaks backwards compatibility
(depending on how far back you go) so I thought I better ask:

Should I do such changes on

1. trunk (that would need more changes even)
2. the modernization branch mentioned above
3. a new branch (branching off from where?)

What do people prefer?

Last but not least I'll note that while the product's functionality
is in place after the changes mentioned above the presentation layer
is still broken as the templates need to be adjusted for the new
translation engine.

Raphael



…

No mention of a ZCML slug in documentation for 2.2.0 but I guess that one
is required.

…

I see
http://plone.org/documentation/manual/upgrade-guide/version/upgrading-plo
ne-3-x-to-4.0/updating-add-on-products-for-plone-4.0 Updating add-on
products for Plone 4.0  but I'm not sure where to start on this.
My guess re: the ZCML slug could be wrong. Any steering will be gratefully
appreciated.


See this  from the log:

    ConfigurationError: ('Unknown directive',
u'http://namespaces.zope.org/five', u'traversable')
Deprecated in plone3 and remove in plone4:

http://plone.org/products/ploneflashupload/issues/5

Must be fixed. Any one ?


_______________________________________________
Product-Developers mailing list
[email protected]
http://lists.plone.org/mailman/listinfo/product-developers

Reply via email to