Skip to content

Commit

Permalink
merge nested tal:conditions into one
Browse files Browse the repository at this point in the history
  • Loading branch information
saily committed Jul 14, 2012
1 parent 1a5a756 commit 8a4b4e4
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 6 deletions.
4 changes: 4 additions & 0 deletions CHANGES.txt
Expand Up @@ -8,6 +8,10 @@ Changelog
Don't use list as default parameter value.
[kleist]

- refactory nested tal:conditions in ``navigation_recurse.pt``, merged into
one tal:condition in ul tag.
[saily]

2.3a1 (2012-06-29)
------------------

Expand Down
10 changes: 4 additions & 6 deletions plone/app/portlets/portlets/navigation_recurse.pt
Expand Up @@ -33,12 +33,10 @@
<span tal:content="node/Title">Selected Item Title</span>
</a>

<tal:children condition="python: len(children) > 0">
<ul tal:attributes="class python:'navTree navTreeLevel'+str(level)"
tal:condition="python: len(children) > 0 and show_children and bottomLevel and level < bottomLevel or True">
<span tal:replace="structure python:view.recurse(children=children, level=level+1, bottomLevel=bottomLevel)" />
</ul>
</tal:children>
<ul tal:attributes="class python:'navTree navTreeLevel'+str(level)"
tal:condition="python:len(children) > 0 and show_children and (bottomLevel and level < bottomLevel or True)">
<span tal:replace="structure python:view.recurse(children=children, level=level+1, bottomLevel=bottomLevel)" />
</ul>
</tal:level>
</li>
</tal:navitem>
Expand Down

0 comments on commit 8a4b4e4

Please sign in to comment.