Configuring Siebel Open UI > Customizing Styles, Applets, Fields, and Controls > Customizing Controls >

Customizing the Busy Cursor to Display While a Business Service Executes


You can force a busy cursor to appear while a selected business service is executing. The example in this topic describes how to configure this behavior.

There is a system preference for Busy Cursor Timeout. For more information, see About Preferences.

To display a busy cursor while a Business Service executes

  1. Create an applet with a button that invokes an always-on method.
  2. Create a physical renderer to respond to the method invocation.
  3. Create a business service to be invoked.
    1. The following is an example of a business service.

    function Service_PreInvokeMethod (MethodName, Inputs, Outputs)
    {

    var nReturn = ContinueOperation;
    switch (MethodName) {
    case "ExampleMethod":
    var count;
    for (var i=1; i<4000000; i++) {
    Outputs.SetProperty("OutputProperty", "OutputValue");
    Outputs.SetProperty("ReturnedProperty", Inputs.GetProperty("InputProperty"));
    count++;
    }
    Return = CancelOperation;
    break;
    }
    return (nReturn);
    }

  4. Make sure the business service is invokable from the client using the application user property.
  5. Update the physical renderer to invoke the business service workOnBusyCursor control upon method invocation.
  6. Test your work:
    1. Navigate to any list applet, and then verify that it displays the control that you added.
Creating Property Sets for Client- Side Controls

You can use the following code to create a property set for a control that Siebel Open UI displays in the client:

ClientCtrlPModel.prototype.UpdateModel = function(psInfo){
/// Specify the property set for the control
SiebelAppFacade.ClientCtrlPModel.superclass.UpdateModel.call( this, psInfo );
var variable_name= SiebelAppFacade.PresentationModel.GetCtrlTemplate
("control_name", "display_name", consts.get( "control_type" ), column_index );
ctrlComboInfo.SetPropertyStr(consts.get("control_property"), "property_attribute")

where:

  • variable_name specifies the name of a variable.
  • control_name, display_name, control_type, and column_index are arguments of the GetCtrlTemplate method. For more information about these arguments, see GetCtrlTemplate Method.
  • control_property specifies a control property. For example, SWE_PROP_WIDTH specifies the width of the control, in pixels.
  • property_attribute specifies an attribute of the control that control_property specifies. For example, for the SWE_PROP_WIDTH property, a value of 200 sets the width of the control to 200 pixels.

For example, the following code creates a variable named ctrlComboInfo for the TestCombo control. It sets the width and height of this control to 200 pixels, and centers it

ClientCtrlPModel.prototype.UpdateModel = function(psInfo){

/// Specify the property set for the control

SiebelAppFacade.ClientCtrlPModel.superclass.UpdateModel.call( this, psInfo );

ClientCtrlPModel.prototype.UpdateModel = function(psInfo){

/// Specify the property set for the control

SiebelAppFacade.ClientCtrlPModel.superclass.UpdateModel.call( this, psInfo );

var ctrlComboInfo = SiebelAppFacade.PresentationModel.GetCtrlTemplate ("TestCombo",

"Test Drop Down", consts.get( "SWE_CTRL_COMBOBOX" ), 10 );

ctrlComboInfo.SetPropertyStr(consts.get("SWE_PROP_WIDTH"), "200")

ctrlComboInfo.SetPropertyStr(consts.get("SWE_PROP_HEIGHT"), "200")

ctrlChkboxInfo.SetPropertyStr(consts.get("SWE_PROP_JUSTIFICATION"), "center");

For more information about control_property and property_attribute, see Properties That You Can Specify for Client-Side Controls. For more information about other control properties that you can specify, such as Sort or Vertical Scroll, see the topic that describes the control Applet Object Type in Siebel Object Types Reference.

Properties That You Can Specify for Client-Side Controls

Table 14 describes the properties that you can specify for controls. The Comparable Applet Control or Description column of this table includes the name of the applet control property that is similar to the SWE control property. If no applet control property is similar to the SWE control property, then this column includes a description. For more information about these applet control properties, see the topic that describes controls in the applet object types section of Siebel Object Types Reference.

Table 14.  Properties That You Can Specify for Controls
SWE Control Property
Comparable Applet Control or Description

SWE_PROP_CURR_FLD

Specifies the field that is currently chosen.

SWE_PROP_CASE_SENSITIVE

Specifies to make text in the control case-sensitive.

SWE_PROP_DISP_FORMAT

Display Format

SWE_PROP_DISP_MODE

HTML Display Mode

SWE_PROP_DISP_MAX_CHARS

HTML Max Chars Displayed

SWE_PROP_DISP_NAME

Specifies the label that Siebel Open UI uses to identify this control in the client.

SWE_PROP_FLD_NAME

Field Name

SWE_PROP_HEIGHT

HTML Height

SWE_PROP_HTML_ATTRIBUTE

HTML Attributes

SWE_PROP_IS_BOUND_PICK

Specifies that the control is a bound picklist.

SWE_PROP_IS_ENCODE

HTML Display Mode

SWE_PROP_INPUTMETHOD

MethodInvoked

SWE_PROP_JUSTIFICATION

Text Alignment

SWE_PROP_LABEL_JUSTIFICATION

Specifies the text alignment for a column header that Siebel Open UI displays in a list control.

SWE_PROP_MAX_SIZE

HTML Max Chars Displayed

SWE_PROP_NAME

Name

SWE_PROP_PICK_APLT

Pick Applet

SWE_PROP_POPUP_HEIGHT

Specifies the height of the popup dialog box, in pixels.

SWE_PROP_PROMPT

Prompt Text

SWE_PROP_POPUP_WIDTH

Specifies the width of the popup dialog box, in pixels.

SWE_PROP_IS_DYNAMIC

Specifies whether or not Siebel Open UI dynamically displays values in the control.

SWE_PROP_SPAN

Specifies to span control contents across multiple fields. This property is not applicable for list controls.

SWE_PROP_SEQ

HTML Sequence

SWE_PROP_TYPE

Type, HTML Type, or Field Retrieval Type

SWE_PROP_WIDTH

Width

SWE_PROP_COLINDEX

Specifies the index number of a column.

SWE_PROP_ICON_MAP

Bitmap

SWE_PROP_IS_SORTABLE

Sort

Text Copy of the Client Control Presentation Model File

The following code from the clientctrlpmodel.js file adds example controls to the client. You can examine this code for your reference. To get a copy of this file, see Article ID 1494998.1 on My Oracle Support:

if( typeof( SiebelAppFacade.ClientCtrlPModel ) === "undefined" ){

SiebelJS.Namespace( 'SiebelAppFacade.ClientCtrlPModel' );

//Module with its dependencies

define("siebel/custom/clientctrlpmodel", [], function () {

SiebelAppFacade.ClientCtrlPModel = ( function(){

var consts = SiebelJS.Dependency( "SiebelApp.Constants" );

/* *

* Constructor Function - ClientCtrlPModel

*

* Parameter - Be a good citizen. Pass All parameter to superclass.

* */

function ClientCtrlPModel(proxy){

var m_recordset = [];

SiebelAppFacade.ClientCtrlPModel.superclass.constructor.call( this, proxy);

this.AddMethod( "AddClientControl", null, { core : true } );

// add into method array

this.GetClientRecordSet = function( ) {

return m_recordset ;

};

}

/* Siebel OpenUI uses the ListPresentationModel object to initialize every list applet. So, to maintain the functionality that ListPresentationModel provides, you extend it.*/

SiebelJS.Extend( ClientCtrlPModel, SiebelAppFacade.ListPresentationModel );

ClientCtrlPModel.prototype.Init = function(){

SiebelAppFacade.ClientCtrlPModel.superclass.Init.call( this );

/* Attach Post Handler for LeaveField */

this.AddMethod( "LeaveField", PostLeaveField, { sequence : false, scope : this } );

/* Attach Pre Handler for GetFormattedFieldValue */

this.AddMethod("GetFormattedFieldValue", PreGetFormattedFieldValue, { sequence : true, scope : this } );

/* Attach Handler for Delete Record Notification as well */

this.AttachNotificationHandler( consts.get( "SWE_PROP_BC_NOTI_DELETE_RECORD" ), HandleDeleteNotification );

};

function PreGetFormattedFieldValue(control, bUseWS, recIndex, returnStructure){

if (utils.IsEmpty(recIndex)){

recIndex = this.Get("GetSelection");

}

if (recIndex >=0) {

var clientObj = this.GetClientRecordSet();

var recordSet=this.Get("GetRawRecordSet");

var id = recordSet[recIndex]["Id"];

var flag = false;

var value;

switch(control.GetName()){

case "TestEdit":

value = recordSet[recIndex]["Name"];

flag = true;

break;

}

if (flag){

if( clientObj[id] && clientObj[id][control.GetName()] ){

value = clientObj[id][control.GetName()];

}

else if (clientObj[id]){

clientObj[id ][control.GetName()] = value;

}

else{

var recordclient = {};

recordclient[control.GetName()] = value;

clientObj[id] = recordclient;

}

returnStructure[ "CancelOperation" ] = true;

returnStructure[ "ReturnValue" ] = value;

}

}

}

function PostLeaveField( control, value, notLeave, returnStructure ){

var clientObj = this.GetClientRecordSet();

var currSel = this.Get( "GetSelection" );

var recordSet=this.Get("GetRawRecordSet");

var id = recordSet[currSel]["Id"];

if (clientObj[id]){

switch(control.GetName()){

case "TestEdit":

clientObj[id][control.GetName()] = returnStructure[ "ReturnValue" ] ;

break;

}

}

}

function HandleDeleteNotification(propSet){

var activeRow = propSet.GetProperty( consts.get( "SWE_PROP_BC_NOTI_ACTIVE_ROW" ) );

if( activeRow === this.Get( "GetSelection" ) ){

var delObj = this.GetClientRecordSet();

delObj[ activeRow ] = null;

}

}

ClientCtrlPModel.prototype.UpdateModel = function(psInfo){

/// PS Attribute info for Edit box

SiebelAppFacade.ClientCtrlPModel.superclass.UpdateModel.call( this, psInfo );

var ctrlTxtInfo = SiebelAppFacade.PresentationModel.GetCtrlTemplate ("TestEdit", "Test Edit", consts.get( "SWE_CTRL_TEXTAREA" ), 1);

this.ExecuteMethod( "AddClientControl", ctrlTxtInfo );

};

return ClientCtrlPModel;

} ());

return "SiebelAppFacade.ClientCtrlPModel";

});

}

Configuring Client-Side Multi-Select

Siebel Open UI uses a client-side control implementation to display a Multi-Select check box column in list applets. While this is primarily intended for touch-based devices where multiple selection of rows is not possible using the Shift + Click or Ctrl + Click, it can also be configured for desktop browsers.

The Multi Row Select Checkbox Display user property controls the behavior and availability of the client-side multi-select check boxes. The property can have the following values:

  • TOUCH-HIDE. The multi-select column does not appear on touch devices.
  • TOUCH-SHOW. The multi-select column appears on touch devices.
  • NONTOUCH-HIDE. The multi-select column does not appear on desktop and non-touch based devices.
  • NONTOUCH-SHOW. The multi-select column appears on desktops and non-touch based Touch devices.

When the user property is not configured for an applet, the default behavior is to show the Multi-Select column on touch devices and hide the column on non-touch devices. Administrators can use the user property to override this behavior on a per-list applet basis.

To configure a multi-select check box for a list applet

  1. Open Siebel Tools.

    For more information, see Using Siebel Tools.

  2. In the Object Explorer, click Applet.
  3. In the Applets list, locate the applet that you want to configure.
  4. Add the applet user property to the applet that you located in Step 3:
    1. In the Object Explorer, expand the Applet tree, and then click Applet User Prop.
    2. In the Applet User Props list, add the following applet user property with one of the possible values:
      Name
      Values

      Multi Row Select Checkbox Display

      TOUCH-HIDE, TOUCH-SHOW, NONTOUCH-HIDE, NONTOUCH-SHOW

  5. Compile the applet object.
  6. Restart the Siebel server.

    Your changes will now be visible in the Siebel Open UI client.

Configuring Siebel Open UI Copyright © 2018, Oracle and/or its affiliates. All rights reserved. Legal Notices.