[Zope] hard dtml syntax problem

Jerome Alet alet@unice.fr
Thu, 13 Jul 2000 08:50:17 +0200 (MET DST)


On Wed, 12 Jul 2000, ethan mindlace fremen wrote:

> Jerome Alet wrote:
> > 
> > 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>
> 
> Couldn't you just do a nested dtml-in?  It's kind of hacky, but...
> 
> <dtml-in "objectValues(['Folder']">
>  <dtml-in "objectValues(['Folder']">

No this can't help because I don't know how deep is my hierarchy: I've
delegated folder creations to at least ten persons.

I'm sure I can do it with ZopeFind, because Zope do it in the Find
(Advanced) tab, but don't know the exact syntax of: 

""" obj_expr = "not objectValues(['Folder'])" """ 

(which doesn't work because of nested " and ')

Actually I've put a <dtml-if> inside of my <dtml-in> loop, but it limits
my possibilities, especially because my result length is overestimated
(all folders vs only folders with no subfolders).

thanks anyway for your answer.

bye,

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