Technology Blogs by Members
Explore a vibrant mix of technical expertise, industry insights, and tech buzz in member blogs covering SAP products, technology, and events. Get in the mix!
cancel
Showing results for 
Search instead for 
Did you mean: 
Former Member

“The value help framework allows easy integration to Business Suite systems…” – Easy integration? Really?

The blog by Owen Pettiford - http://scn.sap.com/community/process-orchestration/blog/2015/04/28/13-reasons-to-migrate-from-sap-pi..., mentions that the value help framework allows easy integration to Business Suite systems.


But is it really that easy? Well yes… actually it is!

Firstly, for anyone who’s not familiar with F4 value help functionality, how is it used?


You’ll no doubt have seen the UI elements:



                                            

                                      

The data that appears in selection popups or dropdown lists might be just static lists, or else might need to come from some back-end system, like ECC or CAF.


So, for example, you click on the Value Help icon for Country (or click in the field and press F4), you get a popup with country values and their corresponding descriptions:


         

  

Or select the dropdown icon on the client field to see a dynamic list of clients:  


Using earlier versions of SAP Process Orchestration, populating the contents of these lists could be a long-winded process. Not such a problem perhaps where you have a static list of values, but if you want to populate the list with dynamic data from ECC, or from your CAF database it takes quite a bit of work.


e.g. if using CAF, you might need to:

    • Create and expose a service in your Data Access Development Component
    • Create request and response message data types
    • Add an Operation to your service to read your Business Object data
    • Create a business logic development component
    • Create and expose a service which consumes your Data Access service
    • etc

The new functionality in versions of SAP Netweaver Process Orchestration 7.3 EhP1 since SP10 simplifies this enormously.

Now, with a bit of configuration upfront in NetWeaver Administrator, you have access in your UIs to data from either ECC, or CAF, in just a couple of lines of code. And as an added bonus, your list will be available to all the applications running on your PO server.


                              



Configuration

To expose the values to your application, you must first configure them as an Alias in SAP Netweaver Administrator, in Configuration --> Connectivity --> Value Help (or just search for 'Alias', then click Alias Configuration)

Here you can create aliases which can then be used by all applications on your PO server. Or you can limit their use by assigning application-specific roles to the alias.

They can be ABAP Aliases, using an existing value help resource from ECC, or DB Aliases, which connect to your specified data source, e.g. an existing table in CAF.



ABAP Alias

For an ABAP Alias, your settings will be something like:

Where Object Type, Method Name, Parameter, Field, Search Help and Value and Description Columns can all be obtained from Business Objects in ECC.

DB Alias
For a DB/CAF Alias, it’s more straightforward still:


Note: you MUST have a language column on your CAF table. If you don’t want/need to use internationalisation, you still have to have a language column, then default the value in the column, to match your system default language, e.g. “en”. If you don’t, you won’t get any descriptions back.

Roles

Add the required roles. You do need at least one role, though it can, if you like, just be ‘Everyone’. If you want to restrict the use of your Alias to certain applications, you can use an application-specific role.

You’ll also need to add the following actions to the role(s) you’ve just assigned to your Alias:

  • SAP_BPM_VALUE_HELP
  • SAP_BPM_VALUE_HELP_ADMIN

Filters

For added flexibility, you can specify filters, to restrict the values returned, for example where the contents of one dropdown is dependent on the selected value in another.

UI Implementation

First you need to add the following dependencies to your Development Component:

  • tc/bpem/facade/ear – for exception handling
  • tc/bpem/valuehelp/ear - value help
  • tc/je/usermanagement/api - forced logged in user for authentication

Using the Value Help API, you can now easily access your values

Value Help API:

  • getHelpValues( URI uri )
  • getHelpValues( URI uri, boolean forceCacheRefresh )
  • getHelpValues( URI uri, long notOlderThan )
  • refreshValueHelpCache( URI uri )
  • refreshAllValueHelpCaches( )

Note: By default, the system caches the values, which is great if the source is perhaps down for maintenance. But it does mean that you must explicitly refresh the cache as and when required.

WDJ

If developing WDJ pages, in your java code, you can get the list of data in just 2 lines, e.g.

URI salesOrgUri = new URI("valuehelp://ALIAS/SalesOrg");

        List<HelpValue> values

                                          = HelpValueManagerFactory.createValueHelper().getHelpValues(salesOrgUri, true);

Each HelpValue object has an ID, value and description (displayText), which you can use however you want, simply by calling getValue() and getDisplayText().

UI5

The syntax in UI5 is as simple, e.g. for OData:

var salesOrgUri = "/bpmodata/valuehelp.svc/SalesOrg ";

var salesOrgModel = new sap.ui.model.odata.ODataModel(salesOrgUri, true);

Bind your model to a table and the data (Value & DisplayText) to columns and you’re away!

Internationalisation

Just add the required language to the URI;

  1. e.g. URI salesOrgUri = new URI("valuehelp://ALIAS/SalesOrg?lang=fr");

Filter

Add your filter value to the URI;

  1. e.g. filter=<filterAliasName>:<filter value>, operation(EQ|CP|LT|NE|LT|LE|GE|GT);
Labels in this area