[Zope] hard dtml syntax problem

Jerome Alet alet@unice.fr
Tue, 11 Jul 2000 14:06:46 +0200 (MET DST)


Hi want to call ZopeFind to find all folders in the current folder which
doesn't have got any subfolder.

the following query works but returns all folders, even those which have
got subfolders:

<dtml-let myresult="ZopeFind(this(), obj_metatypes=['Folder'],
search_sub=1)">
<dtml-in myresult>
...
</dtml-in>

So I play a little with the Zope Search Interface and I find that if I
type in "not objectValues(['Folder']" (without the double quotes) in the
obj_expr (Expression) field then this solves my problem.

my question is:

How to rewrite my ZopeFind with obj_expr="not objectValues(['Folder'])" ?

I've tried with or without quotes (single, double and even triple ones),
but with no luck: I've always got a Document Template Parse Error.

What is the correct syntax please ?

Actually I've added a test inside my dtml-in loop but I think it's stupid
because I need the exact result length and I don't want to rebuild a list
of matching results since the Zope Search Interface can do it.

thanks in advance for any answer.

Jerome ALET - alet@unice.fr - http://cortex.unice.fr/~jerome
Faculte de Medecine de Nice - http://noe.unice.fr - Tel: 04 93 37 76 30 
28 Avenue de Valombrose - 06107 NICE Cedex 2 - FRANCE