Thursday, October 9, 2008

SAP Absolute Navigation Web Dynpro ABAP Portal Integration

You can activate absolute path navigation for the portal in Web Dynpro ABAP using the portal manager (interface IF_WD_PORTAL_INTEGRATION, method NAVIGATE_ABSOLUTE). You can generate a template using the wizard, in which you then enter values.

With the absolute navigation tool, you must know the name of the page to be displayed in order to pass it to the method.

data lr_componentcontroller type ref to ig_componentcontroller .

data l_api_componentcontroller type ref to if_wd_component.

data lr_port_manager type ref to if_wd_portal_integration.

lr_componentcontroller = wd_this->get_componentcontroller_ctr( ).

l_api_componentcontroller = lr_componentcontroller->wd_get_api( ).

lr_port_manager = l_api_componentcontroller->get_portal_manager( ).

call method lr_port_manager->navigate_absolute

exporting

navigation_target = navigation_data-target

navigation_mode = navigation_data-navigation_mode

window_features = navigation_data-window_features

window_name = navigation_data-window_name

history_mode = navigation_data-history_mode

target_title = navigation_data-target_title

context_url = navigation_data-context_url

post_parameters = ABAP_FALSE

use_sap_launcher = abap_true

business_parameters = bus_parameter_list

launcher_parameters = launcher_parameter_list.

The navigation target is the only parameter required here. It stands for an absolute address in the portal. The other parameters are used for controlling the navigation and are optional. You can set business parameters and parameters for the respective application launcher in the portal. To transport business parameters correctly to the target application, you have to set the parameter USE_SAP_LAUNCHER. If it is an SAP application (for example, BSP Web Dynpro, and so on), you have to set the switch to TRUE.

Overview of Parameters

Name

Optional

Possible values

Description

NAVIGATION_TARGET


Address,
for example
ROLES://portal_content/
web_dynpro_abap/
web_dynpro_abap_tester/
portal_integration/
portalNavigation/
portal_navigation_target

Absolute address, path for page or iView in the portal content directory.

This path is displayed in the portal catalog – for instance, when you edit a page or an iView.

NAVIGATION_MODE

″INPLACE″

Displays the navigation target on the same page

Navigation mode

″EXTERNAL″

Displays the navigation target on a new page, but only as an iView, without the portal

″EXTERNAL_PORTAL″

Displays the navigation target on a new portal page.

WINDOW_FEATURES

″TOOLBAR″

Displays the standard toolbar

Additional JavaScript parameters for the external window – for example, character set or size specification, such as width=300 or height=250

These parameters are separated by commas. Spaces are not permitted.

″LOCATION″

Displays the Web address

″DIRECTORIES″

Displays the directory buttons of the browser

″STATUS″

Displays the status bar

″MENUBAR″

Displays the menu bar of the browser

″SCROLLBARS″

Displays the scroll bar

″RESIZABLE″

Windows can be resized

″WIDTH″

Width of the window

″HEIGTH″

Height of the window

WINDOW_NAME

String

Title of the target page in the external browser. The specified Web address is loaded into a window of this name – for instance, MyWindowName. This name is used to access the address.

HISTORY_MODE

″ALLOW_DUPLICATIONS″

A navigation entry can be listed more than once in the history.

Specifies whether the visited Web address should be listed in the navigation history.

″NO_DUPLICATIONS″

A navigation entry can be listed only once in the history.

″NO_HISTORY″

No navigation entry in the history

TARGET_TITLE

String

Title of the portal page

CONTEXT_URL

String

Determines the navigation context used

POST_PARAMETERS

″TRUE″

Transfer parameters as a POST request

Transfer options for parameters

“FALSE” (default value)

Transfer parameters as a GET request

USE_SAP_LAUNCHER

“TRUE” (default value)

Target is called using the SAP launcher – for example, BSP

SAP launcher is used

″FALSE″

Target is not called using the SAP launcher

BUSINESS_PARAMETERS

See structure WDR_NAME_VALUE_LIST with name and value pairs

Transfer parameters for navigating to the target application (Web Dynpro or other Web application), for example, a specific customer number. These parameters are transferred by URL.

See also Structure linkURL Parameters

Keep in mind the transfer restrictions – for example, a parameter cannot be larger than 1 KB.

LAUNCHER_PARAMETERS

See structure WDR_NAME_VALUE_LIST with name and value pairs

Parameter list for the application launcher, parameter list – for example, WebDynproNamespace=myNamespace







If you define BUSINESS_PARAMETERS as application parameters in your Web Dynpro application and the parameter names start with ″APP″, they will automatically be forwarded to the startup plugs of the Web Dynpro application – provided they are marked as startup parameters. In this case, keep in mind that the iView/page used as the navigation target must be assigned to the user role. If it is not, navigation cannot be triggered.

Example

You can find an example in the system in the Web Dynpro application, WDR_TEST_PORTAL_NAV_PAGE.

No comments:

Archive