[Zope] Avoid or supress heredity
Martin Stötzel
martin@stoetzel.com
Tue, 29 May 2001 10:17:26 +0200
Hi all,
I have been trying and trying - but I could not find out:
The problem is that I want to check if a certain file (method) exists in a
folder, and if not, display another method.
I am talking about a 'default_en' which should be displayed if it is in a
folder
and a 'default' which exists in each folder and should be displayed
otherwise.
To make this clear:
root:
default
default_en
+ folder1
- default
+ folder2
- default
- default_en
OK, everything works, exept in folder1. I check if a 'default_en' is there,
otherwise display 'default'. But what happens is that because of heredity
the 'default_en' from the root is found and displayed.
The code is simple:
<dtml-if "'default_en' in objectIds('DTML Method')">
<dtml-var default_en>
<dtml-else>
<dtml-var default>
</dtml-if>
Does anybody know how I could display the 'default' in folder1? (I mean,
with the functionality I want)
Thanks. Martin