Oracle WebCenter 11g PS3: Working with Navigation Models and Page Hierarchies

0
48
3 min read

 

Oracle WebCenter 11g PS3 Administration Cookbook

Oracle WebCenter 11g PS3 Administration Cookbook

Over 100 advanced recipes to secure, support, manage, and administer Oracle WebCenter 11g with this book and eBook

        Read more about this book      

(For more resources on this subject, see here.)

Creating a navigation model at runtime

Lots of administrators will not have access to JDeveloper, but they will need to manage navigation models. In WebCenter, you can easily create and manage navigation models at runtime.

In this recipe, we will show how you can add navigation models at runtime.

Getting ready

For this recipe, you need a WebCenter Portal application.

How to do it…

  1. Run your portal application.
  2. Log in as an administrator.
  3. Go to the administration page.
  4. Select Navigations from the Resource tab.
  5. Press the Create button.
  6. Specify a name, for example, hr.
  7. Specify a description, for example, Navigation model for HR users.
  8. Leave copy from empty. In this list, you can select an existing navigation model so the newly created model will copy the content from the selected model.
  9. Press the Create button:

    Oracle WebCenter 11g PS3 Administration tutorial

The navigation model is now created and you can add components to it.

How it works…

When you add a navigation model at runtime, an XML file will be generated in the background. The navigation model will be stored in the MDS. You can request the path to the actual xml file by selecting Edit properties from the Edit menu when you select a navigation model. In the properties window, you will find a field called Metadata file. This is the complete directory to the actual XML file.

There’s more…

Even at runtime, you can modify the actual XML representation of the navigation model. This allows you to be completely flexible. Not everything is possible at runtime, but when you know what XML to add, you can do so by modifying the XML of the navigation model. This can be done by selecting Edit Source from the Edit menu. This way you will get the same XML representation of a navigation model as in JDevleoper.

Adding a folder to a navigation model

A folder is the simplest resource you can add to your navigation model. It does not link to a specific resource. A folder is only intended to organize your navigation model in a logical way.

In this recipe, we will add a folder for the HR resources.

Getting ready

We will add the folder to the default navigation model so you only need the default WebCenter Portal application for this recipe.

How to do it…

  1. Open default-navigation-mode.xml from Web Content/oracle/Webcenter/portalapp/navigations.
  2. Press the Add button and select Folder from the context menu.
  3. Specify an id for the folder. The id should be unique for each resource over the navigation model.
  4. Specify an expression language value for the Visible attribute.

How it works…

Adding a folder to a navigation model will add a folder tag to the XML with the metadata specified:

<folder visible="#{true}" id="hr">
<attributes>
<attribute isKey="false"
value="folder" attributeId="Title"/>
</attributes>
<contents/>
</folder>

The folder tag has a contents tag as a child. This means that when you add a resource to a folder, these will be added as a child to the contents tag.

There’s more…

You can also add a folder at runtime to a navigation model. This is done by selecting your navigation model and selecting Edit from the Edit menu. From the Add menu, you can select Folder. You are able to add the id, description, visible attribute and iconUrl.

LEAVE A REPLY

Please enter your comment!
Please enter your name here