Navigation within a Web Application
Within a web application, there are various ways of navigation, that is, switching between different components. By default, the menu is created from the display names (displayName
) of the components. Users can use this menu to access the corresponding components.
Other navigation options include the definition of a custom action and overwriting the select
action in the list component of a master structural element within a master/detail component. These two options can also be used to navigate to subcomponents within a master/detail component.
Navigation with an Action
The following example shows how to define an action that navigates to the component with the componentName
name
.
<CustomAction displayName="Navigate" componentName="name" />
The action in this example navigates regardless of whether something is selected in the master/detail component. The selectionNeeded
attribute can be used to bind the action to a selection:
<CustomAction displayName="Navigate" componentName="name" selectionNeeded="true" />
Navigation by overwriting the select
action
The following example shows a master/detail component with overwritten select
action in the master structural element:
<MasterDetailComponent xmlns="http://softproject.de/webapp/1.0">
<Properties>
<Property name="List" type="Complex">
<Property name="Value" type="String" />
</Property>
</Properties>
<Master>
<ListComponent name="list" process="fillListProcess.wrf">
<Actions>
<SelectAction process="select.wrf" /> <!-- Overwritten select action -->
</Actions>
</ListComponent>
</Master>
<Detail>
<DetailComponent name="Detail">
<FlowLayout>
<Label value="#List.Value" />
</FlowLayout>
</DetailComponent>
</Detail>
</MasterDetailComponent>
select.wrf:

select.xml:
<?xml version="1.0" encoding="UTF-8" ?>
<Ok componentName="Detail2" />
In this example, the Detail2 component is always used as the detail component for the selection in the master/detail component. The Technical Process that is bound to the overwritten select
action returns a response containing the given componentname
attribute. This gives the instruction to navigate to the corresponding component.
This example is very simple, it is possible to include complex mappings and conditions in the Technical Process that returns the response to select a detail for display in each individual case.
An example for a master/detail component with project structure can be found in the corresponding section.
The attributes of components, actions, properties and the data binding mechanism can also be found in the corresponding sections.