[Zope-CMF] Once again: CMF-in-CMF

Thomas Olsen tol@tanghus.dk
Mon, 22 Apr 2002 19:19:25 +0200


Hi

Its an often used subject but a new problem - I think.

I am making a customer portal where customer can have different sites ins=
ide a=20
normal CMF Site. Each customer must use their own UserFolder agains which=
 the=20
users of their sites authenticate.

To do this I have created:
 - NPCustomerFolder derived from PortalFolder.
 - NPCustomerObject derived from PortalFolder, PortalContent and=20
DefaultDublineCoreImpl=20
 - NPPortal derived from PortalObjectBase and DefaultDublinCoreImpl.

The setup looks something like this:

Zope
  |_portal (CMF Site)
     |_customers (NPCustomerFolder)
           |__customer_1 (NPCustomerObject)
           |      |_site_1 (NPPortal)
           |      |_site_2 (NPPortal)
           |      |_acl_users
           |
           |__customer_2 (NPCustomerObject)
                  |_site_1 (NPPortal)
                  |_site_2 (NPPortal)
                  |_acl_users

As the Member data is tied to members in a customer object I have also cr=
eated=20
a modified portal_memberdata tool which saves the member data in the cust=
omer=20
object.=20

Everything works ok for users defined in the user folder in an=20
NPCustomerObject but for users defined in acl_users in e.g. Zope root I g=
et=20
all kinds of errors where CMFCore.MembershipTool.createMemberDataArea rep=
orts=20
that the aq_inner attribute is missing and so on.

I'm not asking for a shrinkwrap solution just maybe for some guidelines t=
o=20
what I should be aware of when creating such a setup.

I have read a lot of source in CMFCore, CMFDefault, AccessControl etc. bu=
t I'm=20
still confused. For example: where does the membership tool find users in=
=20
User Folders higher in the folder hierarchy when __getPUS() only returns =
the=20
first User Folder and have does SecurityManager find the authenticated us=
er=20
and what came first - the chicken or the egg?

Sorry for the lengthy post - I'll dig some more in the source :-)
--=20
Regards,
=09Thomas Olsen