Zopists, Is there any way to get a tree tag to render from search results so that you can "turn down" the *result* and see it's children? <dtml-in "objectValues()" size=10 skip_unauthorized reverse> <dtml-let a=sequence-item> <dtml-tree expr="a.PARENTS[1]"> <dtml-var id> </dtml-tree> </dtml-let> </dtml-in> The above code doesn't work. I'll bet it's trivial but I'm missing it. All my best, -- Jason Spisak 444@hiretechs.com
Jason Spisak wrote:
Zopists,
Is there any way to get a tree tag to render from search results so that you can "turn down" the *result* and see it's children?
<dtml-in "objectValues()" size=10 skip_unauthorized reverse> <dtml-let a=sequence-item> <dtml-tree expr="a.PARENTS[1]"> <dtml-var id> </dtml-tree> </dtml-let> </dtml-in>
The above code doesn't work. I'll bet it's trivial but I'm missing it.
If it's trivial, I couldn't tell. What won't work is adding more than one tree, which you do by iterating the objectValues. Perhaps you could assign the objectValues parents to a list (in the same way you now try to tree them) and take that as an input for your tree? Like so (UNtested): <dtml-call "REQUEST.set('plist', [])"> <dtml-in "objectValues()" size=10 skip_unauthorized reverse> <dtml-let a=sequence-item> <dtml-call "plist.append(a.PARENTS[1])"> </dtml-let> </dtml-in> <dtml-tree plist> etc. BTW, are you acquainted with Anthony Baxter's How-To: Some Neat Tricks with dtml-tree. It might give you some ideas. URL: http://www.zope.org/Members/anthony/tree-coding-tricks Rik
Rik:
If it's trivial, I couldn't tell.
That makes me feel better.
What won't work is adding more than
one tree, which you do by iterating the objectValues. Perhaps you could assign the objectValues parents to a list (in the same way you now try to tree them) and take that as an input for your tree? Like so (UNtested):
<dtml-call "REQUEST.set('plist', [])"> <dtml-in "objectValues()" size=10 skip_unauthorized reverse> <dtml-let a=sequence-item> <dtml-call "plist.append(a.PARENTS[1])"> </dtml-let> </dtml-in> <dtml-tree plist> etc.
I'll give it a shot.
BTW, are you acquainted with Anthony Baxter's How-To: Some Neat Tricks with dtml-tree. It might give you some ideas. URL: http://www.zope.org/Members/anthony/tree-coding-tricks
You bet. I read it. Thanks, Jason Spisak CIO HireTechs.com 6151 West Century Boulevard Suite 900 Los Angeles, CA 90045 P. 310.665.3444 F. 310.665.3544 Under US Code Title 47, Sec.227(b)(1)(C), Sec.227(a)(2)(B) This email address may not be added to any commercial mail list with out my permission. Violation of my privacy with advertising or SPAM will result in a suit for a MINIMUM of $500 damages/incident, $1500 for repeats.
participants (2)
-
Jason Spisak -
Rik Hoekstra