WebCenter Spaces: Removing the profile (username) tab (contd.)

person Bijeshfolder_openWebCenteraccess_time December 6, 2010

Contd from here.

I’ve managed to solve this. Thanks to the Oracle support note 1068828.1, we looked at MDS customizations as an option. It’s still a bit of a hack but works for our case.

We customized ¬†LocalBoilerPlate.jspx under localToolBar. The hack was to append an additional test condition to the rendered property on the commandNavigationItem in the wcNavigationPane (which represents the primary tab bar). The addition tests that the tab’s label is not the the same as the logged in username. So, the complete value for the rendered attribute will be
#{tab.visible and (tab.truncatedLabel ne securityContext.userName)}

The MDS customization looks thus


  
    
  

Update: Thanks to rekarnar who pointed out that using the above hack produces Javascript errors when navigating using the tabs. These don’t seem to affect the functionality but then they exist. On further testing, the JS errors only occurs when navigating into the last tab on Spaces. Weird. Anyway, a better hack would be to use the “visible” attribute instead of “rendered”. Also, the truncatedLabel (as the name suggests) truncates longer usernames, so changed that to use the label attribute instead.

Comments

  1. Hrm.. how does one customise the LocalBoilerPlate? I too have the requirement to remove the ‘webcenter’ tab, but am unsure on the next steps to take.

  2. ahhh execellent! Thanks that looks perfect, I have only been using the ‘Extending WebCenter Spaces’, I was un aware of this. :)

  3. So it appears that the link to the required files no longer works: http://www.oracle.com/technology/products/webcenter/files/oracle.webcenter.customization_application.zip

    Perhaps you have a copy to share, or are aware of a new approach?

  4. I should’ve pointed you to the whitepapers page – http://www.oracle.com/technetwork/middleware/webcenter/white-papers-088385.html

    The whitepaper is “WebCenter Task Flow Customization”. You’ll find the supporting files alongside

  5. Wow, how have I never seen this page before! This is amazing! I have been trawling the Oracle site for ages trying to find something this revelant. Thanks heaps :)

  6. Hi Bijesh,

    Sorry to keep bugging you here and de-railing this post, but I have another question and have been searching all over for the last few days trying to solve it. Now, as a last resort I come to you. :)

    In the above white paper page, they link this to file:
    http://www.oracle.com/technetwork/middleware/webcenter/oracle-129395.zip

    But now the accompanying PDF mentions this:
    Navigate to oracle.WebCenter.WebCenterapp.view.taskflows.globalToolbar.

    My issue is that the Zip contains none of these files. Am I ment to recreate the tree is this path from files found on my server? Or has Oracle simply put a fairly empty project file up instead?

  7. @rek: If you click the “Navigator Display Options” button alongside the Projects accordion, there’s an option “Show Libraries”. Ensure it is ticked. I think the whitepaper does mention this.
    The files referenced in the whitepaper are within the library “WebCenter Spaces View”. There are a few other steps the whitepaper mentions to setup JDeveloper for spaces customization. Ensure that you have applied those changes as well.

  8. Ah ha! The whitepaper does indeed mention this. And after following its (and yours) instruction all is visible. A million thanks. I have no idea how I missed that. Well, I do, I guess I was being slack, thankyou again for getting me back on track.

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>