Thursday, December 10, 2009

Siebel Unified Messaging Framework - Part 2

In the first post of this threefold mini-series we introduced the Siebel Unified Messaging Framework (UMF) which is part of the Customer Order Management module.

In the second part of the series I would like to introduce a way to use UMF to display message outside of the order management screens.

The goal is to provide a path for developers to display messages in both active (popup) or passive manner (in a list applet) and capture end user responses without the need for browser scripting. The example follows the recommendations of My Oracle Support (namely document 757843.1). If you wish to view the document, you need a My Oracle Support account.

The example uses UMF (rather the Unified Messaging Service) to display a dialog indicating to the end user that the account he or she has just saved has a status of "Inactive". The dialog has buttons ("Continue" and "Cancel") which the user should click to either continue with the changes or cancel the operation. Part 3 of the series (future post) will describe the steps to capture the responses in a more sophisticated manner.

1. Create the message type

In the Siebel client, navigate to Administration - Order Management | Message Types and create a new message type to define the dialog.

Set the following fields
  • Name = Enter a unique name
  • Display Mode = Active
  • Group = Internal Error Message
  • Title = UMF Test Message (or figure out a better title)
  • Bitmap = select a bitmap (you can upload bitmaps using the Administration - Document screen)
  • Short Text = enter a short text
  • Full Text = enter the message text (this will be displayed to the user). You can use substitution fields using square brackets. You have to add anything between square brackets to the Payload list.
Click the Responses view tab and enter two responses. Use the screenshot below as a guide. You can skip the Field, Business Service and Method fields for now.

Make a note of the Message Type name, you will need it later.

2. Add/verify business object components

In Siebel Tools, navigate to the Account business object and ensure that the following business components are listed.
  • UMF Active Message Virtual BusComp
  • UMF File Handler
  • UMF Passive Message Virtual BusComp
Compile the business object if necessary.

3. Create a wrapper business service to call the Unified Messaging Service

Document 757843.1 includes sample eScript code which can be used as a starting point to create a custom business service which acts as a wrapper. As the input for the Unified Messaging Service methods is quite complex, the custom business service helps us to pass parameters to the Unified Messaging Service.

The purpose of the code is to read a flat input property set and pass the values to a hierachical structure which is needed by the Unified Messaging Service's AddMessages method.

This is the hierarchy of property sets to be generated:

Message List

The script below (click to enlarge) accomplishes this task and invokes the UMS method.

Compile the business service.

4. Create a workflow to invoke the wrapper business service

We can use a workflow process to enable easy invocation of the wrapper business service. The following is a prototype which passes the values to the business service.

To invoke the workflow we can use one of the well known techniques such as a button (using the Named Method user property) or runtime event.

5. Test

I have placed a simple button on the account list applet. When i click the button, the workflow is invoked and the message is displayed as specified.

Note that [Account] (as defined in the message type) has been replaced by the account's real name. Now let's click the Continue button and verify that a response for the account has been created in the Responses screen.


We have successfully used the Siebel Unified Messaging Framework to display a custom dialog with response buttons to the user and to capture the users response as a response record. In the final post of this series we will see how to capture the users responses using custom business services. The above prototype has been implemented on Siebel SIA using the sample database.

Continue to part 3.

have a nice day



Petka17 said...

I have a problem with Unified Messages. I create a Workflow which constructs a PropertySet "MessageList" through the Workflow Utilities Service and then directly invokes the Unified Messaging Service. Well, when I trigger that workflow via a button on the service request form applet it works properly and I get a dialog box. But if I try to use another event, such as WriteRecord or SetFieldValue, it doesn't work. Could explain this behavior?

PS: Thank you for this article!

@lex said...

Hi Petka, I don't have an explanation but I too noticed that the first (!) invocation through a runtime event didn't work. Repeated invocations invoked the workflow.
This is why we went for a custom button...

have a nice day


Anonymous said...

Hi Alex - We've a requirement where when an address is updated in Siebel by sales rep or data steward it will be send for data cleansing to make sure its valid US postal address.

We call a web service where it returns US postal address along with original address.

Before web service updates address in Siebel we've to show both original address and cleansed address to users and if user accept new address then only we've to allow the address update.

Can we use UMF to popup meesage that displays both original and new address and allow uddates if rep approves the changes?

@lex said...

Hi Anonymous,

technically it should be possible to use UMF (if you can pass the address data as payload).

However, I am not able to verify this and therefore I strongly recommend that you also contact Oracle Support.

have a nice day