[CMF-checkins] CVS: CMF - PortalFolder.py:1.6.2.2
tseaver@digicool.com
tseaver@digicool.com
Tue, 10 Apr 2001 00:08:39 -0400 (EDT)
Update of /cvs-repository/CMF/CMFCore
In directory korak:/tmp/cvs-serv30916/CMFCore
Modified Files:
Tag: CMF-1_0-branch
PortalFolder.py
Log Message:
- Filter type objects using 'isConstructionAllowed' in
'PortalFolder.allowedContentTypes' (Tracker issue #249).
--- Updated File PortalFolder.py in package CMF --
--- PortalFolder.py 2001/04/09 15:48:00 1.6.2.1
+++ PortalFolder.py 2001/04/10 04:08:38 1.6.2.2
@@ -183,12 +183,14 @@
if myType is not None:
for contentType in portal_types.listTypeInfo():
- if myType.allowType(contentType.Type()):
- result.append(contentType)
+ if myType.allowType( contentType.Type() ):
+ result.append( contentType )
else:
result = portal_types.listTypeInfo()
- return result
+ return filter( lambda typ, container=self:
+ typ.isConstructionAllowed( container )
+ , result )
security.declareProtected(AddPortalFolders, 'manage_addPortalFolder')
def manage_addPortalFolder(self, id, title='', REQUEST=None):