[Zope-CMF] Getting folder contents of objects derived form portal folder
Rainer Thaden
Rainer Thaden <Thadi@gmx.de>
Thu, 30 May 2002 23:36:27 +0200
Maybe this problem has been discussed here, but i didn't find the
answer for my problem:
I derived a ZClass from PortalContent, PortalFolder and
DefaultDublinCoreImplementation.
I created a hierarchy like this:
CMFroot
Employees (Portal Folder)
emp1 (Instance of my ZClass)
Then i tried to put some portal content inside 'emp1' and faced a
problem:
In the actions box of the view 'emp1' the url for 'Folder Contents' is
Employees/folder_contents and not Employees/emp1/folder_contents.
So i can't take a look into the contents of my ZClass via the actions
box.
If i enter the url Employees/emp1/folder_contents the view for the
folder contents of my ZClass is shown.
Now i can add e.g. a link, which exists in the instance but isn't
shown by the emp1/folder_contents method.
I took a look into the source code of the actions tool and found that
the getFilteredActionsFor(arg) method checks if arg is a portal folder
and if not climbs in the containment hierarchy until it finds a portal
folder and returns the actions for it.
Why is the instance of my ZClass not considered as portal folder?
--
Thanks,
Rainer Thadi@gmx.de