Menu Item and Custom Action Properties

Properties for a menu item or custom action selected on the Screen Design page.

General

Property Description
Name A text label for the menu item.
Note: To prevent menu item names from wrapping on Apple iOS devices, keep the name length to 10 or fewer characters.
Key A key, unique within the current scope, that identifies the item.
Note: If the value is not unique, the Problems view reports a missing key error.
Default Specifies that the menu item is displayed prominently on the screen.
Icon Displays an icon with a menuitem that is in the footer on iOS devices. No other devices or locations are supported. Available icons represent common functions such as navigation arrows, Delete, and Search.
Type The type of action the item performs:
  • Save – closes the current open screen, validates the current input, and saves the the collection of response values to be sent to the server.
  • Open – indicates the screen to be opened with a GoTo connection. The Open type menu item must be associated with a screen on the Flow Design.
  • Close Hybrid App – allows the user to leave the client-side component no matter which screen the client-side component currently shows.
  • Cancel – allows the user to close the current open screen without performing any data validation, and returns the user to the underlying screen.
  • Online Request – creates a synchronous call to the server, validates the data input on all open screens, saves it, sends it to the server and waits for a response from the server before continuing.
  • Submit Hybrid App – creates an asynchronous call to the server, validates the data input on all open screens, closes the application, and sends the data to the server. You cannot invoke Submit Hybrid App on a nested or child, element.

    A Submit Hybrid App menu item allows the user to update, delete, or create data even when not connected to the network. When the user connects, data is automatically sent and received.

    The Submit Hybrid App menu item of the first screen in the Designer must be associated with an MBO operation or an invoke parent update. If the user has multiple screens open at the time of the submit execution, and one of the underlying screens fails validation, the application displays the configured warning message and the submit process stops.

  • Select Certificate – opens a dialog where the user can choose a certificate to use for the credentials.
  • Add/Update/Delete Key Collection – adds, updates, or deletes a key from a key collection from a list key that is bound to a Listview control. These operations do not run immediately, but during a Submit operation on the parent MBO. You can add a key collection only to screens that users access by clicking a row in a Listview.
  • Reset Credentials – enables the user to authenticate using different credentials.
  • Reset Activation – enables the user to request that an activation sequence (such as a maximum number of login attempts) be restarted.
  • Custom – enables you to enter custom code to define the action.
Details Section
Property Action Type Description
The properties in the Details section vary depending on the action type.
Mobile business object Online Request, Submit Hybrid App The MBO with which the menu item is associated. Click Search to locate the MBO.
Invoke parent update Online Request, Submit Hybrid App No changes are made to the parent MBO, but the appropriate operations (create, update, delete) are performed on its descendants.
Invoke operation Online Request, Submit Hybrid App Runs the selected operation for a selected MBO.
Invoke object query Online Request, Submit Hybrid App Runs the specified object query from the item.
Generate old value keys Online Request, Submit Hybrid App Specifies that old value keys are generated (default). If unselected, old value keys are not generated, resulting in a much smaller message and improved performance. However, if you need the old value keys for update or parent update operations, you should leave the property selected.
Show credential screen on authentication failure Online Request, Submit Hybrid App The credential screen displayed when authentication fails. If unselected, authentication failures are treated the same as other types of failures.
Execute asynchronously Online Request, Submit Hybrid App Specifies that the call does not wait until the current operation completes, but starts immediately. By default, the call is synchronous.
Timeout Online Request The maximum amount of time, in seconds, to wait for the server to respond before timing out and giving an error message.
Store data in on-device cache Online Request Enables query results to be stored in the device cache as defined in the on-device cache properties below. When unselected (default), query results are stored only in server cache.
On-device Cache Properties Online Request If Store data in on-device cache is selected, these properties control parameters for caching query results.
  • Timeout:
    Never Expires – Specifies that query results are cached on the device indefinitely.
    Expiration interval – The time, in seconds, that query results are cached on the device. If the same query is made with the same parameter values within the specified timeout, the results are fetched from the device cache and no call to the server is made.
  • Cache Lookup Policy:
    Get results from on-device cache first – Sets policy to look up results on the device before the server.
    Get results from server first – Sets policy to look up results on the server before the device.
Screen Open The screen that opens when the user clicks the item, or as the result of a GoTo connection.

Parameter Mappings

Online requests and custom actions can bind parameters in Mobile Business Object (MBO) operations and object queries to keys or context data that are used in the submitted messages. The Parameter Mappings properties are generated as metadata in WorkflowClient.xml, which defines all the application's action mappings.

The Parameter Mappings table shows the available parameters in MBO operations and object queries, and their current mappings. The Edit button opens the Parameter Mapping dialog, where you can modify the properties of a selected mapping.

For information about parameter mapping, see WorkflowClient.xml File in Developer Guide: Hybrid Apps.

Property Generated WorkflowClient.xml File Metadata
Parameter name The name of the parameter in the operation or query that contains the data.
Parameter type The type of parameter in MBO terms.
Mapping type The source of the data, one of these types:
  • Key
  • BackEndPassword
  • BackEndUser
  • DeviceId
  • DeviceName
  • DeviceType
  • UserName
  • MessageId
  • ModuleName
  • ModuleVersion
  • QueueId
  • ContextVariable
Key The key whose corresponding value is used as the value for this parameter. Used only when the Mapping type is Key.
Return data to client Includes the key data in the return message to the client. If not selected, key data from the mapping is omitted.

Personalization Key Mappings

This page lists any personalization keys. To define the value of a personalization key, select its row in the list and click Edit.

Personalization keys allow the mobile user to personalize specific input field values by associating a key with a value. If your mobile business object has load parameters mapped to transient personalization keys, you can specify the key values that are loaded when an operation or object query is invoked from the Hybrid App package. This can be useful, for example, in loading specific data from large data sources into a consolidated database.

You can also fill the personalization key values with values extracted from the notification, depending on from where you are invoking the object query.

For more information, see Managing Personalization Keys in SAP Mobile WorkSpace - Mobile Business Object Development.

Property Description
Personalization key The name of the personalization key.
Key An operation argument, load argument, or synchronization parameter that provides the value of the personalization key.
Project The project in which this personalization key is created. The personalization key appears in the Personalization Key folder of the selected Mobile Application project.

Output Keys

Lists keys you want an Online Request menu item or custom action to load from the server and return to the client.

Property Description
Key Name A key whose value is resolved by the server and returned to the client.
Type The type of the selected key (read-only).
Data Binding The data binding, if any, associated with the key (read-only).

You can use these buttons to manage the list of output keys:

Success/Error

The Success/Error section contains the following properties when you select the Online Request type in the General section.

Property Description
Submit error message Text of the message the user sees if there is an error during the submit operation.

When an operation is invoked, the user can receive any error messages that may occur on the client application. The error messages are a single key of the List type, with a single key of the String type as its child. Each child instance corresponds to an error message.

Error Screen The screen that opens if an asynchronous operation invocation fails. You can select an existing screen or click Generate Error Screen to create a new one.

If no error screen is specified, the client application receives the notification in processDataMessage/processWorkflowMessage, whether or not an error occurrs on the server. If errors occur on the server, any error log keys sent with the message include the relevant error messages. The log files on the server also contain the specifics of those errors.

Default Success Screen The screen to open upon successful communication with the server.
Condition table Enables you to apply custom functions that to override the default navigation between screens in the running Hybrid App. During package generation, the conditional navigation screen adds a call to the customConditionalNavigation function. The function evaluates each piece of custom logic one at a time, in order, and returns a boolean value. When the first condition comes back as true, the user is navigated to the matching screen for that condition.

For more information about customizing screen navigation, see Implementing Conditional Navigation in Developer Guide: Hybrid Apps

The Success/Error section contains the following properties when you select the Submit Hybrid App type in the General section.

Property Description
Submit confirmation message (Optional) Text that is displayed in a message box when the submit operation finishes successfully.
Resubmit confirmation message Specifies that the resubmit confirmation message is displayed if the option Mark message as processed after processing is enabled in the Flow Design page properties, and if the user attempts to submit the workflow after it has already been previously submitted.
Error screen The screen to which the user navigates if an asynchronous operation invocation fails. You can select an existing screen or click Generate Error Screen to create a new one.

If no error screen is specified, the client application receives no notification of the failure — failures appear only in the log files.

Subject A subject for a notification that is sent to the device, with appropriate error log keys, if an error occurs.
Note: The subject can reference the screen name and action name using macros (except in server-initiated workflows). For example:

"An error occurred trying to perform the ${action} action on the ${screen} screen.

From Text for the From field of the notification that is sent to the inbox when an error occurs.
Note: The subject can reference the screen name and action name using macros (except in server-initiated workflows). See the Subject example.