On 11/08/2010 11:14 AM, Gilles Lenfant wrote: > Le 8 nov. 2010 à 10:18, Simone Orsi a écrit : > >> hi, >> >> I need to create a product that deletes any user's content on user >> deletion. I googled and grepped here and there and it seems there's no >> event fired on user deletion. >> >> The only "right way" to do that seems to create an IUserManager PAS >> plugin to handle it but IMHO that means much work to be done only to >> have an event hook. The other solution, obviously, is monkey-patching, >> which becomes even more bad since that part of PluggableAuthServ is >> already patched by PlonePAS. >> >> Is this right? Do I have to create a plugin? > > Hi, > > I ran into this some times ago. See https://dev.plone.org/plone/ticket/7948 > > Was not for content but for user properties. Seems that Tarek Ziade started > something in the Zope dev ML (PAS is a Zope hosted component) but I dunno the > progress status. > > Note that it is very difficult to handle users from external sources deletion > (LDAP, RDBMS, ...) since there's no event bus that goes to Zope. > > Cheers
hi Gilles, thank for the link. Why is so difficult? I mean, what is needed IMO is an event hook on the plone/zope side which gets triggered everytime a user is deleted, non matter the source of the deletion. Am I missing some inner implication? What's needed also is a flag (just after "enable user folder") that triggers contents deletion. PS: also, a flag for turning on user folder deletion is needed (as pointed out in plone/app/controlpanel/usergroups.py:258) but this is another story :) _______________________________________________ Product-Developers mailing list [email protected] http://lists.plone.org/mailman/listinfo/product-developers
