Java method similar to wpsNavTreeLevel in WP 5.0.2
Web Server forum
Back To The Forum Home!Search!Private Messaging System

Web Server Talk Web Server Talk > Web Servers reviews > WebSphere > WebSphere Portal Server > Java method similar to wpsNavTreeLevel in WP 5.0.2




  Last Thread   Next Thread Next
  Show Printable Version Email this Page Subscribe to this Thread      Post New Thread    Post A Reply      

    Java method similar to wpsNavTreeLevel in WP 5.0.2  
RuneH


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
01-26-07 12:22 PM

I have managed to get the objectid of the current selected node

ModelUtil _modelUtil = ModelUtil.from(request);
ContentNode _currentNode = ((NavigationNode)_modelUtil.getNavigationSelectio
nModel().getSelectedNode( )).getContentNode();
_currentNode.getObjectID;

Not difficult, the code is copied from one of the jsp-files provided in the 
Portal. But the one thing I'm not able to figure out is how to get the _curr
entNode menulevel, equals to wpsNavTreeLevel. I need it to create the menu j
ust as I want it. I found t
he navigation API here http://www-1.ibm.com/support/entdoc...uid=swg27004260 The 
wpsNavTreeLevel is described here http://publib.boulder.ibm.com/pvc/w...#navigationloop

Since the jsp-tag is able to get the navlevel I would assume that it should 
be possible to get it via the Java api as well?

Anyone who knows?

Rune
 ****************************************
**********
Rune Hellem http://hellem.org





[ Post a follow-up to this message ]



    Re: Java method similar to wpsNavTreeLevel in WP 5.0.2  
RuneH


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
01-26-07 12:22 PM

Just to be even more precise, if this had been possible I would have had no 
problem

<wps:navigation startLevel="<%= wpsNavTreeLevel  %>"
stopLevel="<%= wpsNavTreeLevel + 1%>">
<wps:navigationLoop>
<!-- Loop at level <%= wpsNavTreeLevel  %>-->

But since wpsNavTreeLevel is only accessible inside the wps:navigationLoop I
 need to do something else, but right now I don't know what...

(and yes - I have to use 5.0.2 :-( .... )

R.
 ****************************************
**********
Rune Hellem http://hellem.org





[ Post a follow-up to this message ]



    Re: Java method similar to wpsNavTreeLevel in WP 5.0.2  
RuneH


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
01-29-07 12:22 AM

I was able to create a workaround at least. I had to do the loop twice, the 
first time just to get hold of the wpsNavTreeLevel attribute, then I was abl
e to do like this the next time

<wps:navigation stopLevel="<%= level.toString() %>">

where level is an Integer like wpsNavTreeLevel, but available for all jsp-fi
les.

R.
 ****************************************
**********
Rune Hellem http://hellem.org





[ Post a follow-up to this message ]



    Sponsored Links  




 





   All times are GMT. The time now is 11:09 PM.      Post New Thread    Post A Reply      
  Last Thread   Next Thread Next


Most Popular forums 

Forum Jump:
Rate This Thread:

Forum Rules:
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is OFF
vB code is ON
Smilies are ON
[IMG] code is OFF
 
Medical and Health forum | Computer Games Reviews | Graphics design forum

Back To The Top
Home | Usercp | Faq | Register