You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@myfaces.apache.org by Apache Wiki <wi...@apache.org> on 2005/11/22 21:06:16 UTC
[Myfaces Wiki] Update of "Use Facelets with Tomahawk" by AaronAston
Dear Wiki user,
You have subscribed to a wiki page or wiki category on "Myfaces Wiki" for change notification.
The following page has been changed by AaronAston:
http://wiki.apache.org/myfaces/Use_Facelets_with_Tomahawk
The comment on the change is:
Added sample/simple workaround for tree2.
------------------------------------------------------------------------------
Thomas Jachmann
+ ----
+ It turns out that tree2 does not work seamlessly with Facelets. The attributes 'showNav', 'showLines' etc
+ require a Facelets Tag Handler as they are not handled in the manner anticipated by Facelets. However, you use
+ the following workaround:
+
+ {{{
+ <t:tree2
+ id="menuTree"
+ value="#{menu.treeModel}" var="node" varNodeToggler="t"
+ org.apache.myfaces.tree2.CLIENT_SIDE_TOGGLE="#{menu.booleanFalse}"
+ org.apache.myfaces.tree2.SHOW_ROOT_NODE="#{menu.booleanFalse}"
+ org.apache.myfaces.tree2.SHOW_LINES="#{menu.booleanFalse}"
+ org.apache.myfaces.tree2.SHOW_NAV="#{menu.booleanFalse}"
+ >
+ ...
+ </t:tree2>
+ }}}
+
+ Where 'org.apache.myfaces.tree2.SHOW_ROOT_NODE' is the internal name (as a String) of the showRootNde attribute. These must be bound to Boolean values as that is the datatype expected internally by MyFaces code.
+
+ I'm not sure if the above is easier than writing a Facelet Tag Handler or not ... for me (with the (ahem) documentation I have) it was easier.
+
+ Aaron Aston
+