[Zope-CMF] Store development with CMF (new guy)

Eric CESTARI eric@ohmforce.com
Sat, 31 May 2003 02:10:44 +0200

I have reimplemented portal_memberdata as a folder containing ZSQL to=20
my Postgres database.
I can successfully populate my  MemberData object and get the info in=20
the forms.
Modifying the user properties does not work.
For some reason, I have portal_membership.registerMemberData() called=20
twice (hence 2 inserts in the database) :
- one with the new value
- one with the old value (over-riding the good value)

I also have issues with user creation. exUserFolder works ok with=20
authentication, but I can't create a user through the join_form. There=20=

is no error message ...Would I have better luck with a stock CMF site.=20=

My Postgres log show no attempts at inserting the data.

Do you have any hints or pointers about such integration ?
Le mercredi, 28 mai 2003, =E0 03:53 Europe/Paris,=20
sean.upton@uniontrib.com a =E9crit :

>> Both.  No application should access portal_memberdata; that
>> is a detail
>> private to portal_membership.  portal_memberdata might not exist, yet
>> applications can assume that members have certain properties, either
>> through the existence of a portal_memberdata tool or directly through
>> the user object.  However, there is no documented way for
>> applications
>> to find out *which* properties are available.  I have not
>> found a way to
>> solve that problem, since user folders provide no common API for
>> property discovery.  Perhaps we need to standardize on the property
>> management API.
> Yes... especially if such standardization could have the side-benefit=20=

> of
> informally preventing interface-compliant applications from direct=20
> attribute
> access.  Direct access to attributes turns out to be problematic for
> non-ZODB backends; this could be solved by using Python 2.2+=20
> properties, but
> I would prefer to avoid this route for now. As it is now, in order to=20=

> make
> my tools work with applications that try to access properties as=20
> attributes,
> my portal_memberdata.wrapUser() creates memberdata objects that=20
> subclass
> PropertyManager, and calls a method to sync the properties with the =
> values prior to wrapping and returning the member object, and
> notifyModified() has to be explicitly called on the member by any skin
> method changing the properties to sync the property values back to the=20=

> backend - this is kludgy.  Perhaps this problem will go away once I=20
> get over
> my worries about migrating to Python 2.2 and use properties with =
> set/get, or get time to wrap my head around APE and use the stock=20
> tools...
> Sean
> _______________________________________________
> Zope-CMF maillist  -  Zope-CMF@zope.org
> http://mail.zope.org/mailman/listinfo/zope-cmf
> See http://collector.zope.org/CMF for bug reports and feature requests