SVN: GenericSetup/trunk/utils.py - implemented 'remove' directive for generic objects

Yvo Schubbe <[email protected]> Sun, 12 Feb 2006 12:31:15 -0500 (EST)
Newsgroups gmane.comp.web.zope.public-cvs
Message-ID <[email protected]>
Log message for revision 41605:
  - implemented 'remove' directive for generic objects

Changed:
  U   GenericSetup/trunk/utils.py

-=-
Modified: GenericSetup/trunk/utils.py
===================================================================
--- GenericSetup/trunk/utils.py	2006-02-12 17:27:57 UTC (rev 41604)
+++ GenericSetup/trunk/utils.py	2006-02-12 17:31:15 UTC (rev 41605)
@@ -548,6 +548,10 @@
             parent = self.context
 
             obj_id = str(child.getAttribute('name'))
+            if child.hasAttribute('remove'):
+                parent._delObject(obj_id)
+                continue
+
             if obj_id not in parent.objectIds():
                 meta_type = str(child.getAttribute('meta_type'))
                 __traceback_info__ = obj_id, meta_type

_______________________________________________
Zope-CVS maillist  -  [email protected]
http://mail.zope.org/mailman/listinfo/zope-cvs

Zope CVS instructions: http://dev.zope.org/CVS