5Customizing Siebel Open UI

Customizing Siebel Open UI

This chapter describes how to customize Siebel Open UI. It includes the following topics:

Guidelines for Customizing Siebel Open UI

This topic describes guidelines for configuring Siebel Open UI. It includes the following information:

Some Siebel Open UI customizations use the same configuration that a Siebel Business Application uses. For example, you can use the information that Configuring Siebel Business Applications describes to configure the following items in Siebel Open UI:

  • List applets

  • Form applets

  • Views that contain more than one applet

  • Applet controls and list columns

Guidelines for Customizing Presentation Models

It is recommended that you apply the following guidelines if you configure a presentation model:

  • Make sure you customize Siebel Open UI so that the user-interface state is separate from the rendering of this state. The guidelines in this topic describe how to do this.

  • Add a new presentation model only after you consider all other customization options, such as modifying code in a Object Definition Html or using Siebel Tools to modify an object. To examine some examples that do not modify the presentation model, see Customizing Siebel Open UI.

    A presentation model implements the entire abstraction of the user interface content, so the predefined implementation of a presentation model implements the predefined abstraction. There are only a few types of basic user interface abstractions, such as single record, list, tree, and so on. It is recommended that you use a predefined presentation model for each of these basic abstractions that Oracle provides you.

  • Make sure Siebel Open UI models all the state variables that it requires to achieve a rich client behavior, and that it models these state variables as presentation model properties. These properties can reside in the presentation model on the client, or the Siebel Server can provide them from an applet. You can add methods that modify these properties and that manage the state changes after you configure Siebel Open UI to add them. Siebel Open UI typically calls these methods due to a user action, or if the server sends a notification. If a method modifies the logical state of the user interface, then Siebel Open UI uses the AttachPMBinding method to add a binding trigger to the physical renderer. This trigger binds the modified state to the physical user interface. For more information, see AttachPMBinding Method.

Siebel Open UI strictly defines each life cycle method. To help make sure your implementation is clean and readable, it is recommended that you use the following guidelines:

  • Make sure Siebel Open UI uses all presentation model state variables as properties. You must use the AddProperty method to create these properties. You must not use ordinary JavaScript variables to create these properties.

  • Use methods to implement all state changes of the presentation model. Use the AddMethod method to create these methods.

  • Make sure Siebel Open UI uses the AttachEventHandler method to bind each method that the presentation model contains to an event that the physical renderer contains. Each event occurs as the result of some physical user action. This configuration makes sure Siebel Open UI binds each user action to the required logic and modifies the user interface state. For more information, see AttachEventHandler Method.

  • When Siebel Open UI sends a reply, it includes all modifications that occur in the business component layer. It includes these modifications in the reply that it sends in a Notification property set. You must use the AttachNotificationHandler method to add this notification. For more information, see Notifications That Siebel Open UI Supports:

    • Siebel Open UI packages a reply from the server for any predefined type of request. It includes this package in a predefined reply property set. You must use the AttachPSHandler method to add the handler for any property set type that the server sends.

    • You must use the AttachPostProcessingHandle method to add any post-processing handler that does follow up logic on a server request, such as a NewRecord request. You can add this logic after Siebel Open UI finishes processing the reply for this request. Setting the focus for a control is an example of this kind of configuration.

  • Siebel Open UI does the initial setup of the presentation model when it initializes the Siebel view or application, depending on whether the user interface object resides inside or outside of the view. The server sends a property set that includes all the initialization attributes. The proxy uses most of these attributes, but you must use the AddProperty method to get the values that the presentation model requires to set and store the state.

  • You must use the following methods in the physical renderer the first time Siebel Open UI renders the user interface:

    • BindEvents. Binds the presentation model methods to the appropriate events on a control. For more information, see BindEvents Method.

    • BindData. Accesses the presentation model properties, and then sends them to the control through the methods that this control exposes. For more information, see BindData Method.

  • You must configure Siebel Open UI to bind any state changes to the presentation model that occur after the physical renderer finishes the initial rendering. To do this, you configure Siebel Open UI to call the AttachPMBinding method on the physical renderer. This configuration specifies the method that the physical renderer must call or the properties that it must access so that it can send data back to the control. This configuration allows Siebel Open UI to render the user interface after it modifies the presentation model state.

Guidelines for Customizing Physical Renderers

It is recommended that you apply the following guidelines if you configure a physical renderer:

  • Use a physical renderer only to implement methods that render the presentation model state:

    • Do not include any other logic in a physical renderer.

    • Do not include business logic that modifies the user interface state.

    • Do not include manipulations or life cycle control of individual controls or fields. It is recommended that those types of customizations should be maintained separately, in the Plug-in Wrapper.

    • Only use a physical renderer to send user action events to the presentation model, and use the presentation model to do all the work that is necessary to modify a state.

    • Allow the physical renderer to rebind the new presentation model state to the rendered user interface only after the presentation model finishes modifying the state of the logical user interface.

  • Do not use a physical renderer to add any presentation attributes to the Document Object Model (DOM). Example attributes include position, color, or any other styling. To modify a presentation attribute, you must attach or detach a style that you define in a CSS file.

  • Configure Siebel Open UI to do all rendering only in physical renderers or plug-in wrappers. It is strongly recommended that you do not configure Siebel Open UI to do direct DOM manipulation. If you cannot avoid direct DOM manipulation, then you must do this manipulation in a physical renderer or in a plug-in wrapper. Configure Siebel Open UI to send data, metadata, or state information to controls only from a physical renderer. For more information, see About Objects and Metadata.

  • In most situations, if you add a presentation model, then you must also add a corresponding physical renderer. You typically use a presentation model to add custom logic in the client. This logic typically determines a physical behavior that requires a physical renderer to do the rendering. For example, in most situations, you cannot configure a predefined applet that also renders custom logic. Siebel Open UI structures custom JavaScript logic in the presentation model and physical renderer as a customization of predefined Siebel Open UI. This structure allows Siebel Open UI to use JavaScript and to use other logic that a predefined Siebel Open UI implementation provides, such as events, Siebel arrays, and so on. It is not recommended that you configure JavaScript that is independent of Siebel Open UI, and that also modifies Siebel CRM data or physical behavior.

Guidelines for Customizing Plug-in Wrappers

It is recommended that you apply the following guidelines when configuring a plug-in wrapper:

  • Use a plug-in wrapper exclusively to implement methods that manage the life cycle of an individual control or field.

  • Do not include any other logic in a plug-in wrapper.

  • Do not include business logic that modifies the user interface state.

  • Use a physical renderer, exclusively, to send user action events on a field to the presentation model. Use the presentation model to do all the actions that require modifying a state.

  • Allow the plug-in wrapper to rebind the new presentation model state to the rendered control only after the presentation model finishes modifying the state of the logical user interface.

  • Do not use a plug-in wrapper to add presentation attributes to the Document Object Model (DOM). Examples of these types of attributes include: position, color, or any other styling attribute. To modify a presentation attribute, you must attach or detach a style that you define in a CSS file.

  • In most situations, if you add a plug-in wrapper, then you must also add a corresponding physical renderer that interacts with the plug-in wrapper. Typically a plug-in wrapper is used to add custom logic to controls in the client. This logic determines a physical behavior that requires a physical renderer to do the handling for this wrapper.

Guidelines for Customizing Context Renderer

It is recommended that you apply the following guidelines if you configure a context renderer:

  • Use a context renderer exclusively to implement methods that only modify the UI. For example, a context renderer for view can rearrange all the applets in the view as an Accordion panel.

  • Do not include business logic that modifies the user interface state.

  • A context renderer must not try to alter the life cycle of an individual control or field. If required, a plug-in wrapper must be implemented.

  • A context renderer for an applet must not try to alter the Document Object Model (DOM) for the other applets in a view. Similarly, the view based context renderer must not alter the DOM outside of the view container.

  • A context renderer is not an alternative for the Physical Renderer or Plug-in Wrapper. It can be used for a UI operation that can be leveraged by multiple Physical Renderers. For example, in the case of an accordion panel for an applet in a view, you can attach the same context renderer with different custom physical renderer for the view to take advantage of the accordion panel in all views, irrespective of the custom physical renderer.

Guidelines for Customizing Presentation Models and Physical Renderers and Plug-in Wrappers

  1. It is recommended that you apply the following guidelines if you configure the presentation model and physical renderer for a client object:

  • Determine the following items for any element that you intend to customize:

    • The presentation model you must use

    • The plug-in wrapper you must use and the physical renderer that you must use with the presentation model

    • The context renderer you must use.

    • Configure the manifest so that Siebel Open UI can identify the JavaScript files it must download to the client so that it can render the user interface element. For more information, see Configuring Manifests.

    • Modify the physical renderer and presentation model for user interface objects that do not reside in a view, such as navigation tabs. Only one of these elements resides on a single Siebel page, and they do not vary during a Siebel session. So, you can configure the physical renderer and the presentation model for each of these elements in the manifest.

    • You must place all custom presentation models, physical renderers, plug-in wrappers, and context renderers in the custom folder. For more information about this folder, see Organizing Files That You Customize.

Preparing Siebel Tools to Customize Siebel Open UI

This topic describes how to prepare Siebel Tools so that you can use it to customize Siebel Open UI. For more information, see Using Siebel Tools.

To prepare Siebel Tools to customize Siebel Open UI

  1. Open Siebel Tools.

    For more information, see Using Siebel Tools.

  2. Choose the View menu, and then the Options menu item.

  3. Click the Object Explorer tab.

  4. Scroll down through the Object Explorer Hierarchy window to locate the object type you must display

    It is recommended that you set up Siebel Tools to display all object types. To display an object type and all child object types of an object type, make sure the parent includes a check mark with a white background.

  5. Click OK.

Modifying the Application Configuration File

You can use the configuration file to specify parameters that determine how a specific Siebel application runs. For more information about the application configuration file, see Configuring Siebel Business Applications.

To modify the application configuration file

  1. Open Windows Explorer, and then navigate to the following folder:

    INSTALL_DIR\eappweb\bin\language_code
    

    For more information about the language_code, see Languages That Siebel Open UI Supports.

  2. Use a text editor to open the application configuration file that you must modify.

    Each Siebel application uses a different configuration file. For example, Siebel Call Center uses the uagent.cfg file. The application configuration file uses the .cfg file extension.

  3. Locate the section that you must modify.

    Each application configuration file uses brackets to indicate a section. For example:

    [InfraUIFramework]
    
  4. Modify an existing parameter or add a separate line for each parameter that you must specify.

    Use the following format:

    parameter_name = "<param1 param2>"
    

    where:

    • param1 and param2 are the names of the parameters.

    For example:

    TreeNodeCollapseCaption = "<img src='images/tree_collapse.gif' alt='-' border=0 
    align=left vspace=0 hspace=0>"
    

Deriving Presentation Models, Physical Renderers and Plug-in Wrappers

Deriving is a coding technique that you can use with Siebel Open UI to create a reference between two presentation models, physical renderers, or plug-in wrappers. Where Siebel Open UI derives one presentation model, physical renderer or plug-in wrapper from another presentation model, physical renderer or plug-in wrapper. This referencing can make sure that the derived object uses the same logic as the source object. It also helps to reduce the amount of coding you must perform.

The following code includes all the code required to derive one presentation model from another presentation model:

Note: The same methodology can be applied for physical renderers and plug-in wrappers.
if( typeof( SiebelAppFacade.derived_PM_name) === "undefined" ){
  SiebelJS.Namespace( "SiebelAppFacade.derived_PM_name" );
  define( "siebel/custom/derived_PM_name", ["siebel/custom/source_PM"],function(){
    . . .
SiebelJS.Extend(derived_PM_name, SiebelAppFacade.source_PM );
});
}

where:

  • derived_PM_name is the name of a presentation model that references another presentation model.

  • source_PM is the name of a presentation model that provides the code that derived_PM_name uses. The source_PM must already exist.

You must include the define and Extend statements.

For example, the following code derives a presentation model named derivedpm2 from another presentation model, named derivedpm1:

if( typeof( SiebelAppFacade.derivedpm2 ) === "undefined" ){
  SiebelJS.Namespace( "SiebelAppFacade.derivedpm2" );
  define( "siebel/custom/derivedpm2", ["siebel/custom/derivedpm1"], function(){
    . . .
SiebelJS.Extend( derivedpm2, SiebelAppFacade.derivedpm1 );
});
}

Adding Presentation Model Properties That Siebel Servers Send to Clients

This topic describes how to add presentation model properties that the Siebel Server sends to the client.

It is strongly recommended that you configure custom presentation model properties only if the predefined presentation model properties do not meet your requirements.

Adding Presentation Model Properties That Siebel Servers Send for Applets

This topic describes a general approach to customizing applet user properties for presentation models. The Siebel Server sends these properties to the client.

To add presentation model properties that Siebel Servers send for applets
  1. Add user properties to the applet:

    1. Open Siebel Tools.

      For more information, see Using Siebel Tools.

    2. In the Object Explorer, click Applet.

    3. In the Applets list, query the Name property for the applet that you must modify.

      For example, query the Name property for Contact List Applet.

    4. In the Object Explorer, expand the Applet tree, and then click Applet User Prop.

    5. In the Applet User Props list, add the following applet user property.

      Name Value

      ClientPMUserPropn

      For example, ClientPMUserProp1

      user_property_name

      You can specify one or more user properties. Siebel Open UI sends these user properties to the presentation model that it uses in the client to display the applet. To specify more than one user property, use a comma and a space to separate each user property name. For example:

      User Property1, User Property2

      Each user property that you specify must exist in the Siebel repository, and each of these user properties must contain a value in the Value property.

    6. (Optional) Specify more ClientPMUserPropn user properties, as necessary.

      You can specify more than one ClientPMUserPropn user property, as necessary. Repeat Step e for each ClientPMUserPropn user property that you require.

    7. Compile your modifications.

  2. Modify the presentation model:

    1. Use a JavaScript editor to open your custom presentation model file that Siebel Open UI will use to display the applet that you modified in Step 1.

    2. If your custom presentation model does not override the Setup method, then configure Siebel Open UI to do this override.

      For more information about how to configure an override, see Process of Customizing the Presentation Model.

    3. Locate the following section of code:

      presentation_model.Setup(propSet)
      

      For example, if the class name is CustomPM, then locate the following code:

      CustomPM.prototype.Setup = function (propSet)
      
    4. Add the following code to the section that you located in Step c:

      var consts = SiebelJS.Dependency("SiebelApp.Constants");
      var apm = propSet.GetChildByType(consts.get("SWE_APPLET_PM_PS"));
      

      where:

      • SWE_APPLET_PM_PS is a predefined constant that Siebel Open UI uses to get the presentation model properties that it uses to display the applet. The Siebel Server sends these properties in a property set.

    5. Add the following code anywhere in the presentation model:

      var value = apm.GetProperty("user_property_name")
      

      For example:

      var value = apm.GetProperty("User Property1")
      

      You must configure Siebel Open UI so that it runs the Setup method that you specify in Step c before it encounters the code that you add in Step e.

Adding Presentation Model Properties That Siebel Servers Send for_Views

This topic describes how to customize view user properties for presentation models. The Siebel Server sends these properties to the client.

To add presentation model properties that Siebel Servers send for views
  1. Add user properties to the view:

    1. Open Siebel Tools.

      For more information, see Using Siebel Tools.

    2. In the Object Explorer, click View.

    3. In the Views list, query the Name property for the view that you must modify.

      For example, query the Name property for Contact List View.

    4. In the Object Explorer, expand the View tree, and then click View User Prop.

    5. Do Step 1, Step e through Step g, in the topic Adding Presentation Model Properties That Siebel Servers Send for Applets except add view user properties to a view instead of adding applet user properties to an applet.

  2. If your custom view presentation model does not override the Setup method, then configure Siebel Open UI to do this override:

    1. Do Step 2 in the topic Adding Presentation Model Properties That Siebel Servers Send for Applets except use vpm instead of apm:

    2. Use a JavaScript editor to open the presentation model file that Siebel Open UI uses to display the view that you modified in Step 1 in the topic Adding Presentation Model Properties That Siebel Servers Send for Applets.

    3. Add the following code:

      var consts = SiebelJS.Dependency("SiebelApp.Constants");
      var vpm = propSet.GetChildByType(consts.get("SWE_VIEW_PM_PS"));
      

      where:

      • SWE_VIEW_PM_PS is a predefined constant that Siebel Open UI uses to get the presentation model properties that it uses to display the view. The Siebel Server sends these properties in a property set.

    4. Add the following code:

      var value = vpm.GetProperty("user_property_name")
      

      For example:

      var value = vpm.GetProperty("User Property1")
      

      For more information about how to configure an override, see Process of Customizing the Presentation Model.

Customizing Control User Properties for Presentation Models

This topic describes how to customize control user properties for a presentation model.

To customize control user properties for presentation models
  1. Add user properties to the control:

    1. Open Siebel Tools.

      For more information, see Using Siebel Tools.

    2. In the Object Explorer, click Applet.

    3. In the Applets list, query the Name property for the applet that you must modify.

      For example, query the Name property for Contact List Applet.

    4. In the Object Explorer, expand the Applet tree, and then Control.

    5. In the Controls list, query the Name property for the control that you must modify.

      For example, query the Name property for NewRecord.

    6. In the Object Explorer, expand the Control tree, and then click Control User Prop.

    7. In the Control User Props list, do Step 1, Step e through Step g, in the topic Adding Presentation Model Properties That Siebel Servers Send for Applets except add control user properties to the control instead of adding applet user properties to an applet.

  2. Modify the custom presentation model of the applet where the control resides:

    Note: This step can also be accomplished using a plug-in wrapper written for customizing the control.
    1. Configure Siebel Open UI to get the control object. You can do one of the following:

      • Use the following code to get the control object from the GetControls presentation model property:

        var controls = this.Get("GetControls");
        for (var control in controls){
        var cpm = control.GetPMPropSet(consts.get("SWE_CTRL_PM_PS"));
        // Do something with cpm
        }
        
      • Use the following the GetControl method to get an instance of the Account Name control:

        var myControl = this.GetControl ("Account Name");
        var cpm = myControl.GetPMPropSet(consts.get("SWE_CTRL_PM_PS"));
        
    2. Add the following code:

      var consts = SiebelJS.Dependency("SiebelApp.Constants");
      var cpm = control.GetPMPropSet(consts.get("SWE_CTRL_PM_PS"));
      

      where:

      • GetPMPropSet is a method that gets the property set for this control. For more information, see GetPMPropSet Method.

      • SWE_CTRL_PM_PS is a predefined constant that Siebel Open UI uses to get the presentation model that it uses for the control object. The Siebel Server sends these properties in a property set.

    3. Add the following code:

      var value = cpm.GetProperty("user_property_name")
      

      For example:

      var value = cpm.GetProperty("User Property1")
      

Configuring Siebel Open UI to Bind Methods

This topic includes some examples that describe how to bind methods. For other examples that bind methods, see the following topics:

Binding Methods That Reside in the Physical Renderer

You can use the AttachPMBinding method to bind a method that resides in a physical renderer and that Siebel Open UI must call when the presentation model finishes processing.

To bind methods that reside in the physical renderer
  1. Add the method reference in the physical renderer.

  2. Configure Siebel Open UI to send the scope in the binderConfig argument of the AttachPMBinding method as a scope property.

    For more information, see AttachPMBinding Method.

Conditionally Binding Methods

The example in this topic conditionally binds a method.

To conditionally bind methods
  • Add the following code:

    this.AttachPMBinding("DoSomething",function(){SiebelJS.Log("After 
    DoSomething");},{when: function(function_name){return false;}});
    

    where:

    • function_name identifies the name of a function.

In this example, if Siebel Open UI calls DoSomething, then the presentation model calls the function_name that the when condition specifies, and then tests the return value. If function_name returns a value of:

  • true. Siebel Open UI calls the AttachPMBinding method.

  • false. Siebel Open UI does not call the AttachPMBinding method.

If you do not include the when condition, then Siebel Open UI runs the DoSomething method, and then calls the AttachPMBinding method. For more information, see AttachPMBinding Method.

Calling Methods for Applets and Business Services

This topic includes some examples that describe how to call methods for applets and business services. For other examples that call methods, see the following topics:

Calling Methods

The example in this topic describes how to call a method when the user clicks a button.

To call methods for buttons
  1. Modify the plug-in wrapper:

    1. Use a JavaScript editor to open the plug-in wrapper for the button.

    2. Locate the click handler for the button.

    3. Add the following code to the code you located in Step b:

      var inPropSet = CCFMiscUtil_CreatePropSet();
      //Define the inPropSet property set with the information that InvokeMethod sends 
      as input to the method that it calls.
      var ai= {};
      ai.async = true;
      ai.selfbusy = true;
      ai.scope = this;
      ai.mask = true;
      ai.opdecode = true;
      ai.errcb = function(){
        //Code occurs here for the method that Siebel Open UI runs if the AJAX call fails
        };
      ai.cb = function(){
        //Code occurs here for the method that Siebel Open UI runs if the AJAX call is 
      successful
        };
      this.GetPM().ExecuteMethod("InvokeMethod",input arguments, ai);
      

      where:

      • input arguments lists the arguments that InvokeMethod sends as input to the method that it calls.

        For example, the following code specifies to use the InvokeMethod method to call the NewRecord method, using the properties that the inPropSet variable specifies for the ai argument:

        this.GetPM().ExecuteMethod("InvokeMethod", "NewRecord", inPropSet, ai)
        

        For more information, see InvokeMethod Method for Application Models and NewRecord Method.

  2. Modify the presentation model:

    1. Use a JavaScript editor to open the presentation model for the applet that you must modify.

    2. Locate the code that calls the Init method.

    3. Add the following code to the code that you located in Step b:

      this.AttachPreProxyExecuteBinding("method_name", function(methodName, inputPS, 
      outputPS){// Include code here that Siebel Open UI runs before the applet proxy 
      sends a reply.});
      
      this.AttachPostProxyExecuteBinding("method_name", function(methodName, inputPS, 
      outputPS){// Include code here that Siebel Open UI runs after the applet proxy 
      sends a reply.});
      

      where:

      • method_name identifies the name of the method that InvokeMethod calls. Note that Siebel Open UI comes predefined to set the value of the methodName argument in the following code to WriteRecord, by default. You must not modify this argument:

        function(methodName, inputPS, outputPS)
        

        For example:

        this.AttachPreProxyExecuteBinding("WriteRecord", function(methodName, inputPS, 
        outputPS){// Include code here that Siebel Open UI runs before the applet proxy 
        sends a reply.});
        
        this.AttachPostProxyExecuteBinding("WriteRecord", function(methodName, inputPS, 
        outputPS){// Include code here that Siebel Open UI runs after the applet proxy 
        sends a reply.});
        

        For more information, see WriteRecord Method, AttachPostProxyExecuteBinding Method, and AttachPreProxyExecuteBinding Method.

Calling Methods for Business Services

The example in this topic describes how to call a method for a business service when the user clicks a button.

To call methods for buttons
  1. Use a JavaScript editor to open the plug-in wrapper for the button.

  2. Locate the click handler for the button.

  3. Add the following code to the code that you located in Step 2:

    var service = SiebelApp.S_App.GetService("business_service_name");
    if (service) {
      var inPropSet = CCFMiscUtil_CreatePropSet();
      //Code occurs here that sets the inPropSet property set with all information that 
    Siebel Open UI must send as input to the method that it calls.
      var ai = {};
      ai.async = true;
      ai.selfbusy = true;
      ai.scope = this;
      ai.mask = true;
      ai.opdecode = true;
      ai.errcb = function(){
          //Code occurs here for the method that Siebel Open UI runs if the AJAX call fails
        };
      ai.cb = function(){
          //Code occurs here for the method that Siebel Open UI runs if the AJAX call 
    is successful
        };
      service.InvokeMethod("method_name", "input_arguments", ai);
    }
    

    For more information, see InvokeMethod Method for Presentation Models.

Using the Base Physical Renderer Class With Nonapplet Objects

This topic describes how to use the Base Physical Renderer class with nonapplet objects that you customize.

The BasePhysicalRenderer class simplifies calls that Siebel Open UI makes to the AttachPMBinding method for nonapplet objects. You can configure Siebel Open UI to use the BasePhysicalRenderer class to identify the physical renderer, call AttachPMBinding, and specify the configuration for the scope of a nonapplet object. You can then use a custom physical renderer to call AttachPMBinding with the appropriate handler.

Siebel Open UI uses the PhysicalRenderer class to interface with and to render applets. Starting with Siebel CRM versions 8.1.1.11 and 8.2.2.4, it uses the BasePhysicalRenderer class to render nonapplet objects. It uses this class to separate the interface to the physical renderer from the physical renderer. Siebel Open UI uses the BasePhysicalRenderer class only with nonapplet objects, such as the toolbar or predefined query bar.

If your deployment includes nonapplet custom rendering, and if it uses Siebel CRM version 8.1.1.10, 8.2.2.3 or earlier, then it is strongly recommended, but not required, that you modify your configuration so that it uses the BasePhysicalRenderer class to render your custom, nonapplet objects. If your deployment uses the PhysicalRenderer class to render nonapplet objects, then this class will provide access to applet functionality and properties that it does not require to do the rendering, which could degrade performance or result in rendering problems.

Siebel Open UI defines the BasePhysicalRenderer class in the basephyrenderer.js file.

Hierarchy That the Base Physical Renderer Class Uses

The following figure illustrates the hierarchy that the BasePhysicalRenderer class uses for non-mobile applications. The member variable is a variable that is associated with the class. All methods can access this member variable.

Hierarchy That the Base Physical Renderer Class Uses

Using Methods with the Base Physical Renderer Class

The following table describes how to use methods with the BasePhysicalRenderer class.

Table How to Use Methods with the Base Physical Renderer Class

Method Description

Init

Use this method to initialize the BasePhysicalRenderer class. For more information, see Init Method.

GetPM

Use this method to retrieve the presentation model object on which the base physical renderer is running. For more information, see GetPM Method for Physical Renderers.

ShowUI

Use this method to display the DOM area corresponding to this physical renderer. Any customization on rendering of controls owned by this applet should be left to the respective plug-in wrappers. For more information, see ShowUI Method and Deriving Presentation Models, Physical Renderers and Plug-in Wrappers.

BindEvents

Use this method to attach event handlers to the applet area that runs on this physical renderer. Any customizations relating to event attachment to controls owned by this applet should be left to the respective plug-in wrappers. For more information, see BindEvents Method.

BindData

Use this method to bind data attributes to the applet area that runs on this physical renderer. Any customizations relating to event attachment to controls owned by this applet should be left to the respective plug-in wrappers. For more information, see BindData Method and Deriving Presentation Models, Physical Renderers and Plug-in Wrappers.

AttachPMBinding

Use this method to configure Siebel Open UI to do the same work that the AttachPMBinding method does in a presentation model. You can use the following argument to call the AttachPMBinding method:

scope

You can use the following arguments with the AttachPMBinding method:

  • methodName. Identifies the method that the BasePhysicalRenderer class binds.

  • handler. Identifies the handler method that Siebel Open UI uses for this binding.

  • handlerScope. Identifies the scope where the BasePhysicalRenderer class runs the handler. If you do not specify the handlerScope, then the BasePhysicalRenderer class uses the default scope.

For more information, see AttachPMBinding Method.

EndLife

Use this method to end the life of the physical renderer. It is recommended that you use the EndLife method to clean up the custom event handler. This clean up includes releasing events, deleting unused variables, and so on. For more information, see EndLife Method.

Declaring the AttachPMBinding Method When Using the Base Physical

If you configure Siebel Open UI to use the BasePhysicalRenderer class, then you must declare the AttachPMBinding method.

To declare the AttachPMBinding method when using the Base Physical Renderer class
  1. Use a JavaScript editor to open your custom physical renderer.

  2. Locate the Init method.

  3. Add the following code to the Init method that you located in Step 2:

    CustomPhysicalRenderer.prototype.Init = function(){
      // Be a good citizen. Call Superclass first
      SiebelAppFacade.CustomPhysicalRenderer.superclass.Init.call(this);
      // Call AttachPMBinding here.
    }
    

    For example:

    CustomPhysicalRenderer.prototype.Init = function(){
      SiebelAppFacade.CustomPhysicalRenderer.superclass.Init.call(this);
      this.AttachPMBinding("EndQueryState", EndQueryState);
    }
    

Sending an Arbitrary Scope

An arbitrary scope is any scope other than the scope that calls the handler. You can configure Siebel Open UI to send to the AttachPMBinding method any scope that is available in the physical renderer. You can use the BasePhysicalRenderer class to send an arbitrary scope that identifies the handler method that Siebel Open UI must use.

To send an arbitrary scope
  1. Use a JavaScript editor to open your custom physical renderer.

  2. Add the following code to send an arbitrary scope as an argument:

    this.AttachPMBinding ("FocusOnApplet", FocusOnApplet, arbitrary_scope );
    

    For example:

    this.AttachPMBinding ("FocusOnApplet", FocusOnApplet, SiebelAppFacade.S_App);
    

    where:

    • SiebelAppFacade.S_App is an arbitrary scope because it is not the calling scope that the this statement identifies, which Siebel Open UI assumes in BasePR, by default. In this example, the FocusOnApplet handler must exist in the SiebelAppFacade.S_App scope.

Accessing Proxy Objects

If you must write code that accesses a proxy object, then it is strongly recommended that you access this proxy object through a physical renderer. The physical renderer typically exposes the interfaces that allow access to operations that Siebel Open UI performs on the proxy object. The example in this topic accesses a proxy object for an active control.

To access proxy objects
  1. Use a JavaScript editor to open your custom physical renderer.

  2. Add the following code:

    this.ExecuteMethod("SetActiveControl", control);
    

    This example code accesses a proxy object so that Siebel Open UI can modify an active control.

It is recommended that you do not write code that directly accesses a proxy object from a physical renderer. In the following example, Siebel Open UI might remove the GetProxy method from the presentation model, and any code that references GetProxy might fail. It is recommended that you do not use the following code:

this.GetProxy().SetActiveControl(control);

Modifying Nonapplet Configurations for Siebel CRM Version 8.1.1.10, 8.2.2.3, or Earlier

Siebel Open UI removed the scope argument for calls that it makes to the AttachPMBinding method with nonapplet objects, starting with Siebel CRM versions 8.1.1.11 and 8.2.2.4. You can modify your custom code to use this new configuration.

To modify nonapplet configurations for Siebel CRM versions 8.1.1.10, 8.2.2.3, or earlier
  1. Use a JavaScript editor to open your custom physical renderer.

  2. Locate the following code:

    this.GetPM().AttachPMBinding ("FocusOnApplet", FocusOnApplet, {scope:this});
    

    In this example, AttachPMBindings uses the scope argument to do a call in Siebel CRM version 8.1.1.10, 8.2.2.3, or earlier.

  3. Replace the code that you located in Step 2 with the following code:

    this.AttachPMBinding ("FocusOnApplet", FocusOnApplet);
    

    You can use this code starting with Siebel CRM versions 8.1.1.11 and 8.2.2.4.

Creating Components

The example in this topic configures Siebel Open UI to attach a local component

as the child of a view component, and it uses the property set that Siebel Open UI uses to create this component to specify the name of the module.

Siebel Open UI uses this module for the presentation model and the physical renderer.

To create components

  1. Create the property set. Use the following code:

    var psInfo = CCFMiscUtil_CreatePropSet();
    psInfo.SetProperty(consts.get("SWE_UIDEF_PM_CTR"), "siebel/custom/customPM");
    psInfo.SetProperty(consts.get("SWE_UIDEF_PR_CTR"), "siebel/custom/customPR");
    

    where:

    • siebel/custom/customPM is the module name that identifies the siebel/custom/customPM.js presentation model

    • siebel/custom/customPR is the module name that identifies the siebel/custom/customPR.js physical renderer

  2. Create the dependency object. Use the following code:

    var dependency = {};
    dependency.GetName = function(){return "custom_Dependency_object";} 
    

    This example assumes that it is not necessary that this component references an applet, so the code limits the scope to a view.

  3. Call the MakeComponent method. Use the following code:

    SiebelAppFacade.ComponentMgr.MakeComponent(SiebelApp.S_App.GetActiveView(), 
    psInfo, dependency);
    

    For more information, see MakeComponent Method and GetActiveView Method.

Customizing How Siebel Open UI Displays Error Messages

Prior to Siebel CRM release 8.1.1.13, Siebel Open UI used the ErrorObject method to display the error dialog box. This method calls a browser alert method that displays the dialog box as a browser notification. Beginning with Siebel CRM release 8.1.1.13, you can modify this configuration so that Siebel Open UI displays the notification in a status bar or in a custom dialog box.

Siebel Open UI uses the following rendering files to display error messages:

  • errorobjectrenderer.js. Displays an error alert or SWEAlert message.

  • errorstatusbarrenderer.js. Displays an error message in a custom error status bar in the browser.

  • errorpopuprenderer.js. Displays a custom dialog box that includes an error message.

Note the following:

  • The errorobjectrenderer.js file is the only file that comes predefined with Siebel Open UI and does not require you to configure the manifest or to modify a method. You must not modify this file.

  • The errorpopuprender.js file is in the sample folder and must be moved to the custom folder.

  • The manifest does not come predefined to use the errorstatusbarrenderer.js file or the errorpopuprenderer.js file. If your customization requires one of these files, then you must add it to the manifest. Create a manifest files entry with the name siebel/custom.errorpopuprenderer.js

  • Siebel Open UI renders only one of these files at a time. If you add errorstatusbarrenderer.js or errorpopuprenderer.js to the manifest, then Siebel Open UI uses one of these files instead of errorobjectrenderer.js.

  • Create a platform independent entry in the Manifest Administration view with type=Application and level= Common and add the siebel/custom/errorpopuprenderer.js file.

  • Clear the cache and start the application to get errorpopuprenderer.js loaded to the application.

  • Use #_sweview_popup in the CSS file to customize error messages. For example:

    #_sweview_popup {
       color: red !important;
       font-style: italic;
       height: 300px !important;
    }
    
  • These files reference the following method. For more information about this method, see ShowErrorMessage Method:

    ShowErrorMessage(message)
    
  • Each file uses the typical sequence that a physical renderer uses. For example, each file calls the following methods in the following sequence. You must not modify this sequence. For more information, see Life Cycle of a Physical Renderer:

    • ShowUI

    • BindData

    • BindEvents

For more information about configuring error messages in Siebel Open UI, see Configuring Error Messages for Disconnected Clients.

To customize how Siebel Open UI displays error messages

  1. Optional. Modify the style that Siebel Open UI uses when it displays the error status bar.

    If your customization uses the errorstatusbarrenderer.js file, then you can style the status bar by adding style rules for the siebui-statusbar class in a custom cascading style sheet and place it in following folder:

    files\custom\my-style.css
    

    You must add the style sheet to the manifest by following the steps outlined in Configuring Manifests.

  2. Configure the manifest. For more information about how to do this step, see Configuring Manifests:

    1. Log in to a Siebel client with administrative privileges.

    2. Navigate to the Administration - Application screen, and then the Manifest Files view.

    3. Add one of the following files, depending on your customization requirements:

      custom/errorstatusbarrenderer.js
      custom/errorpopuprenderer.js
      
    4. Navigate to the Manifest Administration view.

    5. In the UI Objects list, specify the following object.

      Type

      Application

      Usage Type

      Theme

      Name

      PLATFORM INDEPENDENT

    6. In the Object Expression list, add the following subexpression.

      Field Value

      Group Name

      Leave empty.

      Expression

      Desktop

      Level

      1

      Siebel Open UI only uses the renderer whose level is set to 1.

      Operator

      Leave empty.

      Web Template Name

      Leave empty.

    7. In the Files list, click Add.

    8. In the Files dialog box, click Query.

    9. In the Name field, enter the path and file name that you added in Step c:

      files/custom/my-style.css
      
    10. Click Go.

  3. Test your work:

    1. Log out of, and then log back into the client.

    2. Do something that results in an error.

    3. Verify that the client displays an error message according to your modifications.

Customizing Navigation Options

The Siebel Open UI client can be configured to control the navigation options available to users. By default the Side Menu icon is used to control navigation. Without configuration, two additional options are available for navigation: Tab and Tree.

In some deployments, you might want to restrict the use of a navigation option to a predefined group. This topic explains how to control which navigation options are available to which users.

To customize the available navigation options

  1. Create an expression for the navigation option that you want to restrict:

    1. Log in to a Siebel client with administrative privileges.

    2. Navigate to the Administration - Application screen, and then the Manifest Expressions view.

    3. Click the plus (+) icon to create a new expression.

    4. Specify a name for the expression.

    5. Specify the restrictive expression.

  2. Create a copy of the navigation type that you want to restrict:

    1. Navigate to the Administration - Application screen, and then the Manifest Administration view.

    2. In the UI Objects list, search with the following specifications:

      Field Value

      Type

      Navigation

      Usage Type

      Physical Renderer

      Name

      NAVIGATION*

      You can reference any navigation option.

    3. Select the navigation option that you want to modify. The three available options are NAVIGATION_SIDE, NAVIGATION_TAB, and NAVIGATION_TREE.

    4. Take note of the exact file name that is listed in Files applet, you will need this information in a later step.

    5. Select the Edit menu, then Copy Record.

  3. Edit the navigation type:

    1. Select the copy of the navigation type that you created in Step 2.

    2. Click the plus (+) icon in Object Expression applet.

    3. In the Expression field, specify the expression that you created in Step 1.

    4. Click the plus (+) icon in the Files applet and add the file that you noted in Step 2, Step d.

  4. Verify your work:

    1. Log out of the client, and then log back into the client.

      This step refreshes the manifest.

    2. Navigate to the User Preferences screen, then the Behavior view.

    3. Verify that the correct options are available in the Navigation Control drop-down menu for the user with which you are logged in.

Example of Restricting Navigation Options

The example in this topic describes how to restricts the Tree navigation option to only the ADMIN user in Siebel Open UI.

This topic gives one example of restricting navigation options. You might use this feature differently, depending on your business model.

To restrict the Tree navigation option to only the ADMIN user

  1. Create an expression that restricts availability to administrator only:

    1. Log in to a Siebel client with administrative privileges.

    2. Navigate to the Administration - Application screen, and then the Manifest Expressions view.

    3. Click the plus (+) icon create a new expression.

    4. Specify the following in the Name field:

      Admin Only

    5. Specify the following in the Expression field:

      GetProfileAttr('Login Name') = 'ADMIN'
      
  2. Create a copy of the NAVIGATION_TREE object:

    1. Navigate to the Administration - Application screen, and then the Manifest Administration view.

    2. In the UI Objects list, search with the following specifications:

      Field Value

      Type

      Navigation

      Usage Type

      Physical Renderer

      Name

      NAVIGATION_TREE

    3. Select the NAVIGATION_TREE record.

    4. Select the Edit menu, then Copy Record.

  3. Edit the new NAVIGATION_TREE record:

    1. Select the copy of the NAVIGATION _TREE record.

    2. Click the plus (+) icon in Object Expression applet.

    3. In the Expression field, specify the expression Admin Only.

    4. Click the plus (+) icon in the Files applet to add the following file:

      jsTreeCtrl.js
      
  4. Verify your work:

    1. Log out of the client, and then log back into the client as a user other than ADMIN.

    2. Navigate to the User Preferences screen, then the Behavior view.

    3. Verify that the only the following two options are available in the Navigation Control drop-down menu:

      • Side Menu

      • Tab

    4. Log out of the client, and then log back into the client as the ADMIN user.

    5. Navigate to the User Preferences screen, then the Behavior view.

    6. Verify that the only the following three options are available in the Navigation Control drop-down menu:

      • Side Menu

      • Tab

      • Tree

Refreshing Custom Events

Siebel Open UI does not come predefined to refresh a custom event. The example in this topic describes how to modify this behavior.

To refresh custom events

  1. Add the following code:

    this.AddMethod("RefreshHandler", function(x, y, z){
      // Add code here that does processing for RefreshHandler.
    });
    

    This code adds the RefreshHandler custom event handler.

  2. Add the following code in the presentation model so that it is aware of the event that the RefreshEventHandler specifies:

    this.AttachEventHandler("Refresh", "RefreshHandler");
    

    For more information, see AttachEventHandler Method.

  3. Add the following code in the bindevents method of the plug-in wrapper:

    this.Helper("EventHelper").Manage(buttonEl, "click", { ctx: this }, 
    function(event){
          event.data.ctx.GetPM().OnControlEvent("Refresh", value1, value2, valueN);
    

    This code binds the event to the presentation model. For more information, see OnControlEvent Method.

Overriding Event Handlers

The example in this topic configures Siebel Open UI to override an event handler that the predefined presentation model references.

To override event handlers

  1. Configure Siebel Open UI to refresh a custom event.

    For more information, see Customizing Events.

  2. Add the following code to your custom presentation model:

    this.AddMethod(SiebelApp.Constants.get("PHYEVENT_INVOKE_CONTROL"), 
    function(controlName) {
      // Process button click
      return false;
    });
    

    This code configures Siebel Open UI to return the following value from the event handler. It makes sure this presentation model does not continue processing:

    false
    

Attaching an Event Handler to an Event

This topic describes how to attach an event handler to an event.

To attach an event handler to an event

  • Use the following code:

    this.AddMethod("custom_method", function(){});
    this.AttachEventHandler("custom_event", "custom_method");
    

    The physical renderer or the plug-in wrapper triggers these handlers when the following code is executed:

    this.GetPM().OnControlEvent("custom_event", param1, param2)
    

    The presentation model uses the custom_method to identify the function that it must call and when to call it. The presentation model also sends the parameters that OnControlEvent provides. For more information, see AttachEventHandler Method.

Attaching More Than One Event Handler to an Event

This topic describes how to attach more than one event handler to an event.

To attach more than one event handler to an event

  • Use the following code:

    this.AttachEventHandler("custom_event", "custom_method_1");
    this.AttachEventHandler("custom_event", "custom_method_2");
    this.AttachEventHandler("custom_event", "custom_method_3");
    

    The physical renderer or the plug-in wrapper triggers these handlers when the following code is executed:

    this.GetPM().OnControlEvent( "custom_event",  param1, param2)
    

    The presentation model determines that it must handle three events, and it handles them in the reverse order that you specify them. In this example, it uses the following sequence when it handles the event:

    1. custom_method_3

    2. custom_method_2

    3. custom_method_1

    The presentation model sends the same values for the parameters that OnControlEvent specifies for each event handler.

    For more information, see AttachEventHandler Method.

Stopping Siebel Open UI From Calling Event Handlers

You can configure the AttachEventHandler method to stop calling event handlers at any point during the event handling process. The example in this topic assumes your configuration includes one predefined event handler and three custom event handlers, and that custom_event_handler_2 stops the processing according to a condition.

To stop Siebel Open UI from calling event handlers

  • Use the following code:

    this.AddMethod("custom_event_handler_2", function(param1, param2, returnStructure){
      if(condition){
        returnStructure[consts.get("SWE_EXTN_CANCEL_ORIG_OP") ] = true;
        returnStructure[consts.get("SWE_EXTN_STOP_PROP_OP") ] = true;
        returnStructure[consts.get("SWE_EXTN_RETVAL") ] = return_value ;
      }
    });
    this.AttachEventHandler("event_name", "custom_event_handler_2");
    

    where:

    • consts references SiebelApp.Constants.

    • return_value contains a value that Siebel Open UI returns to the object that called OnControlEvent.

This code does the following work:

  • Sets the SWE_EXTN_CANCEL_ORIG_OP and SWE_EXTN_STOP_PROP_OP properties according to a condition.

  • Stops event handlers from running.

  • Uses SWE_EXTN_RETVAL to return a value to the object that called OnControlEvent.

For more information, see AttachEventHandler Method.

Attaching and Validating Event Handlers in Any Sequence

You can configure Siebel Open UI to attach and validate an event handler in any sequence, depending on your requirements. The example in this topic does some custom validation, and then runs an event handler in a custom presentation model named derivedpm2.js. If the user triggers a control focus event, then Siebel Open UI runs the validator before it calls the event. Siebel Open UI uses the value that the validator returns to determine whether or not to run the custom event handler and the predefined event handler. This predefined event handler is the default event handler that the predefined presentation model uses for the event. This topic describes the derivedpm1.js and derivedpm2.js files. To get a copy of these files, see Article ID 1494998.1 on My Oracle Support.

To attach and validate event handlers in any sequence

  1. Use a JavaScript editor to create a custom presentation model that Siebel Open UI derives from a predefined presentation model:

    1. Create a new file named derivedpm1.js. Save this file in the following folder:

      siebel\custom
      

      For more information about:

    2. Configure the custom derivedpm1 presentation model that you created in Step a so that Siebel Open UI derives it from the predefined ListPresentationModel. You add the following code:

      if( typeof( SiebelAppFacade.derivedpm1 ) === "undefined" ){
        SiebelJS.Namespace( "SiebelAppFacade.derivedpm1" );
        define( "siebel/custom/derivedpm1", [], function(){
          SiebelAppFacade.derivedpm1 = ( function(){
            var siebConsts = SiebelJS.Dependency( "SiebelApp.Constants" ),
              CANCEL_OPR = consts.get( "SWE_EXTN_CANCEL_ORIG_OP" ),
              STOP_PROP = consts.get( "SWE_EXTN_STOP_PROP_OP" );
            function derivedpm1(){
              SiebelAppFacade.derivedpm1.superclass.constructor.apply( this, arguments);
            }
            SiebelJS.Extend( derivedpm1, SiebelAppFacade.ListPresentationModel );
            derivedpm1.prototype.Init = function(){
              SiebelAppFacade.derivedpm1.superclass.Init.call( this );
      

      For more information, see Deriving Presentation Models, Physical Renderers and Plug-in Wrappers.

    3. Make sure the derivedpm1 presentation model includes a handler for the PHYEVENT_COLUMN_FOCUS event. You add the following code:

              this.AttachEventHandler( siebConsts.get("PHYEVENT_COLUMN_FOCUS"), 
      function()
              {
                SiebelJS.Log("Control focus 1");
                arguments[arguments.length - 1][consts.get( "SWE_EXTN_CANCEL_ORIG_OP" 
      )] = false;
              });
      

      For more information about the method that this code uses, see AttachEventHandler Method.

    4. Validate the handler that you added in Step c. You add the following code:

        this.AddValidator(siebConsts.get("PHYEVENT_COLUMN_FOCUS"), function(){
          return true;
        });
      };
      

      For more information about the method that this code uses, see AddValidator Method.

    5. Finish the setup that you started in Step b. You add the following code:

            derivedpm1.prototype.Setup = function(propSet){
              SiebelAppFacade.derivedpm1.superclass.Setup.call( this, propSet );
            };
            return derivedpm1;
          } ());
          return "SiebelAppFacade.derivedpm1";
        });
      }
      
    6. Save your changes, and then close the derivedpm1.js file.

  2. Use a JavaScript editor to create another custom presentation model that Siebel Open UI derives from the custom presentation model that you created in Step 1:

    1. Create a new file named derivedpm2.js. Save this file in the following folder:

      siebel\custom
      

      For more information about this file, see Complete Contents of the derivedpm1 Presentation Model.

    2. Configure the custom derivedpm2 presentation model that you created in Step a so that Siebel Open UI derives it from the derivedpm1 presentation model. You add the following code:

      if( typeof( SiebelAppFacade.derivedpm2 ) === "undefined" ){
        SiebelJS.Namespace( "SiebelAppFacade.derivedpm2" );
        define( "siebel/custom/derivedpm2", ["siebel/custom/derivedpm1"], function(){
          SiebelAppFacade.derivedpm2 = ( function(){
            var siebConsts = SiebelJS.Dependency( "SiebelApp.Constants" ),
              CANCEL_OPR = consts.get( "SWE_EXTN_CANCEL_ORIG_OP" ),
              STOP_PROP = consts.get( "SWE_EXTN_STOP_PROP_OP" );
            function derivedpm2(){
              SiebelAppFacade.derivedpm2.superclass.constructor.apply( this, arguments);
            }
            SiebelJS.Extend( derivedpm2, SiebelAppFacade.derivedpm1 );
            derivedpm2.prototype.Init = function(){
              SiebelAppFacade.derivedpm2.superclass.Init.call( this );
      
    3. Make sure the derivedpm2 presentation model includes a handler for the PHYEVENT_COLUMN_FOCUS event. You add the following code:

      this.AttachEventHandler( siebConsts.get("PHYEVENT_COLUMN_FOCUS"), function()
      {
        SiebelJS.Log("Control focus 2");
      });
      
    4. Validate the handler that you added in Step c. You add the following code:

      this.AttachEventHandler( siebConsts.get("PHYEVENT_COLUMN_FOCUS"), function()
      {
        SiebelJS.Log("Control focus 2");
      });
      this.AddValidator(siebConsts.get("PHYEVENT_COLUMN_FOCUS"), function(row, ctrl, 
      val){
        //custom validation
        }
      });
      

      where:

      • custom validation validates the values.

        For example, the following code validates that the handler handles the Hibbing Mfg account:

        this.AttachEventHandler( siebConsts.get("PHYEVENT_COLUMN_FOCUS"), function()
        {
          SiebelJS.Log("Control focus 2");
        });
        this.AddValidator(siebConsts.get("PHYEVENT_COLUMN_FOCUS"), function(row, ctrl, 
        val){
          if(ctrl.GetDisplayName() === "Account" && val === "Hibbing Mfg"){
            return true;
          }
        });
        
    5. Finish the setup that you started in Step b. You add the following code:

            };
            derivedpm2.prototype.Setup = function(propSet){
              SiebelAppFacade.derivedpm2.superclass.Setup.call( this, propSet );
            };
            return derivedpm2;
          } ());
          return "SiebelAppFacade.derivedpm2";
        });
      }
      
    6. Save your changes, and then close the derivedpm2.js file.

  3. Configure the manifest. For more information about how to do this step, see Adding Custom Manifest Expressions:

    1. Log in to a Siebel client with administrative privileges.

    2. Navigate to the Administration - Application screen, and then the Manifest Files view.

    3. Add the file that you created in Step 2.

      For this example, you add the following file:

      custom/derivedpm2.js
      

      Note that your configuration derives the derivedpm2.js from the derivedpm1.js file, so it is not necessary to add derivedpm1.js to the manifest.

    4. Navigate to the Manifest Administration view.

    5. In the UI Objects list, specify the following object.

      Field Value

      Type

      Applet

      Usage Type

      Presentation Model

      Name

      Opportunity List Applet

      You can reference any list applet. For this example, use Opportunity List Applet.

    6. In the Object Expression list, add the following subexpression.

      Field Value

      Group Name

      Leave empty.

      Expression

      Desktop

      Level

      1

      Operator

      Leave empty.

      Web Template Name

      Leave empty.

    7. In the Files list, add the following file:

      custom/derivedpm2.js
      
  4. Log out of the client, and then log back into the client.

    This step refreshes the manifest.

  5. Verify your work:

    1. Navigate to the Opportunity List Applet.

    2. Click anywhere in the Account field.

    3. Verify that the browser console log displays the following text:

      Control Focus 2
      

      The handler that you specified in the derivedpm2.js file in Step 2 specifies this text.

    4. Verify that the browser console log displays the following text:

      Control Focus 1
      

      The handler that you specified in the derivedpm1.js file in Step 1 specifies this text.

Complete Contents of the derivedpm1 Presentation Model

The following code is the complete contents of the derivedpm1 presentation model:

if( typeof( SiebelAppFacade.derivedpm1 ) === "undefined" ){
  SiebelJS.Namespace( "SiebelAppFacade.derivedpm1" );
  define( "siebel/custom/derivedpm1", [], function(){
    SiebelAppFacade.derivedpm1 = ( function(){
      var siebConsts = SiebelJS.Dependency( "SiebelApp.Constants" ),
        CANCEL_OPR = consts.get( "SWE_EXTN_CANCEL_ORIG_OP" ),
        STOP_PROP = consts.get( "SWE_EXTN_STOP_PROP_OP" );
      function derivedpm1(){
        SiebelAppFacade.derivedpm1.superclass.constructor.apply( this, arguments );
      }
      SiebelJS.Extend( derivedpm1, SiebelAppFacade.ListPresentationModel );
      derivedpm1.prototype.Init = function(){
        SiebelAppFacade.derivedpm1.superclass.Init.call( this );
        this.AttachEventHandler( siebConsts.get("PHYEVENT_COLUMN_FOCUS"), function()
        {
          SiebelJS.Log("Control focus 1");
          arguments[arguments.length - 1][consts.get( "SWE_EXTN_CANCEL_ORIG_OP" )] 
= false;
        });
        this.AddValidator(siebConsts.get("PHYEVENT_COLUMN_FOCUS"), function(){
          return true;
        });
      };
      derivedpm1.prototype.Setup = function(propSet){
        SiebelAppFacade.derivedpm1.superclass.Setup.call( this, propSet );
      };
      return derivedpm1;
    } ());
    return "SiebelAppFacade.derivedpm1";
  });
}

Complete Contents of the derivedpm2 Presentation Model

The following code is the complete contents of the derivedpm2 presentation model:

if( typeof( SiebelAppFacade.derivedpm2 ) === "undefined" ){
  SiebelJS.Namespace( "SiebelAppFacade.derivedpm2" );
  define( "siebel/custom/derivedpm2", ["siebel/custom/derivedpm1"], function(){
    SiebelAppFacade.derivedpm2 = ( function(){
      var siebConsts = SiebelJS.Dependency( "SiebelApp.Constants" ),
        CANCEL_OPR = consts.get( "SWE_EXTN_CANCEL_ORIG_OP" ),
        STOP_PROP = consts.get( "SWE_EXTN_STOP_PROP_OP" );
      function derivedpm2(){
        SiebelAppFacade.derivedpm2.superclass.constructor.apply( this, arguments );
}
SiebelJS.Extend( derivedpm2, SiebelAppFacade.derivedpm1 );
derivedpm2.prototype.Init = function(){
SiebelAppFacade.derivedpm2.superclass.Init.call( this );
this.AttachEventHandler( siebConsts.get("PHYEVENT_COLUMN_FOCUS"), function()
{
SiebelJS.Log("Control focus 2");
});
this.AddValidator(siebConsts.get("PHYEVENT_COLUMN_FOCUS"), function(row, ctrl, 
val){
if(ctrl.GetDisplayName() === "Account" && val === "Hibbing Mfg"){
return true;
}
});
};
derivedpm2.prototype.Setup = function(propSet){
SiebelAppFacade.derivedpm2.superclass.Setup.call( this, propSet );
};
return derivedpm2;
} ());
return "SiebelAppFacade.derivedpm2";
});
}

Customizing the Sequence that Attaches and Validates Event Handlers

The example in this topic illustrates how you can modify the sequence that Siebel Open UI uses to attach and validate event handlers so that it stops any further event handler processing after a validation occurs. It does some custom validation, and then runs an event handler in a file named derivedpm2.js. If the user triggers a control focus event, then Siebel Open UI runs the custom event handler that displays a message in the Browser console log. The validator then returns a value of false, so Siebel Open UI stops any further event handler processing for the custom event handler and for the predefined event handler.

To customize the sequence that attaches and validates event handlers

  1. Do Step 1 in the topic Attaching and Validating Event Handlers in Any Sequence

    .
  2. Do Step 2 in the topic Attaching and Validating Event Handlers in Any Sequence, but specify the validator first, and then the event handler. You use the following code:

    this.Addvalidator(siebConsts.get("PHYEVENT_COLUMN_FOCUS"), function(){
      custom validation
      return true;
    });
    this.AttachEventHandler(siebConsts.get("PHYEVENT_COLUMN_FOCUS"), function()
    {
      Siebjs.Log("Control Focus 2");
    });
    

    For more information about the methods that this code uses, see AddValidator Method and AttachEventHandler Method.

  3. Do Step 5 in the topic Attaching and Validating Event Handlers in Any Sequence, but verify that Siebel Open UI displays the following text in the browser console log:

    Control Focus 2
    Control Focus 1
    

Using AttachEventHandler Prior to Siebel CRM Release 8.1.1.13

Prior to Siebel CRM release 8.1.1.13, the AttachEventHandler method returns one of the following values. This configuration allows AttachEventHandler to attach only one custom event to an event:

  • true. Attached an event handler successfully.

  • false. Did not attach an event handler successfully.

It uses the following syntax:

AttachEventHandler("eventName", eventHandler());

where:

  • eventName is a string that identifies the name of the event that Siebel Open UI must attach to the event.

  • eventHandler identifies the method that Siebel Open UI calls.

For more information, see AttachEventHandler Method.

Overriding the OnControlEvent Method and Then Calling a Superclass

You must not configure Siebel Open UI to override the OnControlEvent method to handle an event, and then call a superclass. For example, assume you configure Siebel Open UI to override the listpmodel.js file, and that the derived class resides in the derivedpm1.js file. Assume you then use the following code to override the OnControlEvent method that resides in the pmodel.js file. This file specifies the base presentation model class:

derivedpm1.prototype.OnControlEvent = function(event_name)
{
}

In this situation, when an event occurs, Siebel Open UI calls the overridden OnControlEvent instead of the pmodel.prototype.OnControlEvent. You must avoid this configuration. For more information, see OnControlEvent Method.

Allowing Blocked Methods for HTTP GET Access

In Siebel Innovation Pack 2014 and later, read and write operations have been separated for all applets, business components, and business service methods.

If you want to allow access to a blocked method for HTTP GET access, a user property has been introduced for applets and business services to include methods on a white list, thereby allowing access using HTTP GET.

This topic describes how to allow blocked methods for HTTP GET access using the GETEnabledMethods user property.

To allow blocked methods for HTTP GET access

  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 or business service to which you want to add the GETEnabledMethods user property.

  4. In the Object Explorer, expand the Applet tree, and then click Applet User Prop.

  5. In the Applet User Props list, add the user property with the values:

    Field Value

    Name

    GETEnabledMethods

    Value

    MethodName1, MethodName2, ... MethodNameN

    Where MethodNameX is the name of a method that should be accessible by way of HTTP GET.

Note: It is recommended to list only read-only methods in the white list for HTTP GET access. Methods that perform write operations should not be listed.

Managing Files

This topic describes how to manage files. It includes the following information:

You also use the manifest to manage files. For more information, see Configuring Manifests.

Organizing Files That You Customize

This topic describes how to organize files that you customize. A predefined file is a type of file that comes configured ready-to-use with Siebel Open UI. A custom file is a predefined file that you modify or a new file that you create. A .png file that you use for your company logo is an example of a custom file. You can customize the following types of files:

  • JavaScript files

  • CSS files

  • Image files, such as .jpg or .png files.

  • HTML files.

  • XML files.

Note the following guidelines:

  • You must modify any relative paths that your custom file contains. For more information, see Updating Relative Paths in Files That You Customize.

  • The folder structures that this topic describes applies to all cached and deployed files.

  • Any third-party libraries that you use must reside in a predefined folder or in a custom folder.

Note: You must not modify any files that reside in the folders that the following table describes. You must make sure that these folders contain only Oracle content, and that your custom folders contain only custom content. This configuration helps to avoid data loss in these folders. If you modify any predefined file, then Siebel Open UI might fail, and it might not be possible to recover from this failure.

To organize files that you customize

  • Store all your custom CSS files and image files that reside on the client in one of the following folders:

    INSTALL_DIR\applicationcontainer\webapps\siebel\files\custom
    INSTALL_DIR\applicationcontainer\webapps\siebel\images\custom
    

    where:

    • INSTALL_DIR is the folder where you installed the client.

    • Store all your custom presentation models and physical renderers in the following folder:

      INSTALL_DIR\applicationcontainer\webapps\siebel\scripts\siebel\custom
      

      Oracle stores predefined presentation models and physical renderers in the following folder. You must not modify any file that resides in this folder:

      INSTALL_DIR\applicationcontainer\webapps\siebel\scripts\siebel
      

Where Siebel Open UI Stores Predefined Files in Siebel Open UI

The following table describes where Siebel Open UI stores predefined files in the Siebel Open UI client. You must not modify any of these files. Instead, you can copy the file, and then save this copy to one of your custom folders.

Table Where Siebel Open UI Stores Predefined Files in Siebel Open UI Clients

File Type Folders Where Siebel Open UI Stores Predefined Files

JavaScript files

Siebel Open UI stores JavaScript files in the following folders:

INSTALL_DIR\applicationcontainer\webapps\siebel\scripts
INSTALL_DIR\applicationcontainer\webapps\siebel\scripts\siebel
INSTALL_DIR\applicationcontainer\webapps\siebel\scripts\3rdParty

These folders contain JavaScript files only for predefined Siebel Open UI. You must not modify these files, and you must not store any custom files in these folders. The 3rdParty folder might contain CSS files that the third-party JavaScript files require.

CSS files

Siebel Open UI stores CSS files in the following folders:

INSTALL_DIR\applicationcontainer\webapps\siebel\files
INSTALL_DIR\applicationcontainer\webapps\siebel\files\3rdParty

These folders contain CSS files only for predefined Siebel Open UI. You must not modify these files, and you must not store any custom files in these folders.

Image files

Siebel Open UI stores image files in the following folders:

INSTALL_DIR\applicationcontainer\webapps\siebel\images

These folders contain image files only for predefined Siebel Open UI. You must not modify these files, and you must not store any custom files in this folder. To support color schemes, Siebel Open UI converts the images that Oracle provides from GIF files to PNG files.

Updating Relative Paths in Files That You Customize

If you customize a file, and if you save this custom file in a custom folder, then you must modify any relative paths that this file references. For example, if you copy the rules from a predefined .css file into a custom .css file, then you must modify the relative paths that your custom .css file references so that they reference the correct file. For an example of this configuration, see Customizing the Logo.

To update relative paths in files that you customize

  1. Create a custom file.

    For more information about custom files, see Organizing Files That You Customize.

  2. Search your custom file for any relative paths.

    For example, images/ in the following code is an example of a relative path:

    src=images/ebus.gif
    
  3. Modify the relative path so that it can correctly locate the file that it references.

    For example:

    src=INSTALL_DIR/applicationcontainer/webapps/siebel/images/ebus.gif
    
  4. Do Step 2 and Step 3 for every relative path that your custom file contains.

Specifying Dependencies Between Presentation Models or Physical Renderers and Other Files

A presentation model or physical renderer sometimes includes a module dependency, which is a relationship that occurs when this presentation model or physical renderer depends on another file. The Define method recognizes each of these items as a JavaScript code module, which is an object that the module_name argument identifies as depending on other modules to run correctly. You specify the module_name argument when you use the Define method to identify the JavaScript files that Siebel Open UI must download for a presentation model or physical renderer. For more information, see Define Method.

Consider the following example that uses the customPR.js file to define the physical renderer. This renderer depends on plug-in X and plug-in Y, and it uses the following directory structure:

In this example, the following logical dependencies exist between the customPR.js file and the x-core.js file, x-helper.js file, and the customPR.js file:



Siebel Open UI then uses the following logic at run-time for this example:

  1. The user navigates to a view that includes an applet that uses the customPR physical renderer.

  2. The Siebel Server server sends a reply to the client that includes information about the property set and the physical layout.

  3. The view processes the information that the Siebel Server sends in Step 2, and then determines that it must use siebel/custom/customPR.js to render the applet.

  4. The RequireJS script loader uses the customPR.js file name to identify siebel/custom/customPR as the module name, and then sends a request to the Siebel Server for this module.

  5. If Siebel Open UI already loaded this module, then it returns the module object to the client and proceeds to Step 7.

  6. If Siebel Open UI has not already loaded this module, then it does the following work:

    1. Sends a request to the Application Interface for the siebel/custom/customPR.js file.

    2. If dependencies exist, then Siebel Open UI sends a request for these dependent modules, and then runs the modules in the browser.

    3. Siebel Open UI runs the script for the siebel/custom/customPR.js file in the browser.

  7. Siebel Open UI uses the module object to create a new instance of the presentation model and the physical renderer.

To help manage your customizations, it is strongly recommended that you use a module name that is similar to the relative location of the file name. You use the manifest administration screens to specify the manifest for these dependencies.

To specify dependencies between presentation models or physical renderers and other files

  1. Use the list_of_dependencies argument when you use the Define method in your presentation model or physical renderer.

    For an example that uses the list_of_dependencies argument, see Setting Up the Physical Renderer. For more information, see Define Method.

  2. If file dependencies require that you configure Siebel Open UI to download files in a specific order, then do Configuring Manifests.

Overview of Configuring Manifests

A manifest is a set of instructions that Siebel Open UI uses to identify the JavaScript files that it must download from the Siebel Server to the client so that it can render screens, views, applets, menus, controls, and other objects. For an overview of how Siebel Open UI uses this manifest, see Example of How Siebel Open UI Renders a View or Applet.

Siebel CRM versions 8.1.1.9 and 8.1.1.10 use an XML manifest file to identify these JavaScript files in the following situations:

  • When Siebel Open UI initializes the Siebel application. Siebel Open UI does this download only for one Siebel application at a time.

  • The first time Siebel Open UI must display an applet in a Siebel application.

Starting with Siebel CRM versions 8.1.1.11 and 8.2.2.4, Siebel Open UI replaces the XML manifest file with manifest data that it stores in the Siebel Database. You cannot modify this predefined manifest data, but you can use the Manifest Administration screen in the client to configure the manifest data that your customization requires. For more information about using a utility that migrates your custom manifest configurations from Siebel CRM version 8.1.1.9 or 8.1.1.10 to version 8.1.1.11 or 8.2.2.4, see the topic that describes migrating the Siebel Open UI manifest file in Siebel Database Upgrade Guide.

Example of How Siebel Open UI Identifies the JavaScript Files It Must Download

The following figure describes an example of how Siebel Open UI uses the manifest to identify the JavaScript file it must download so that it can use the presentation model for the SIS Account List Applet. The manifest maps the recyclebinpmodel.js file that resides in the siebel/custom folder to the presentation model that it uses to display this applet. For details about this example, see Creating the Presentation Model and Configuring the Manifest for the Recycle Bin Example.

Example of How Siebel Open UI Identifies the JavaScript Files It Must Download
Explanation of Callouts

The example manifest administration includes the following items:

  1. The Files list specifies the siebel/custom/recyclebinpmodel.js file.

  2. The presentation model specifies siebel/custom/recyclebinpmodel when it calls the define method.

Example of a Completed Manifest Administration

The following figure includes an example of a completed manifest administration that configures Siebel Open UI to download JavaScript files for the Contact List Applet. For more information about how to configure this example, see Configuring Custom Manifests.


Example Manifest Administration
Explanation of Callouts

The example manifest administration includes the following items:

  1. The Grid group uses the AND operator to group three expressions into the following group expression:

    Desktop AND EditList AND Grid

    A group expression is a type of expression that Siebel Open UI uses to arrange subexpressions into a group in the Object Expression list.

  2. Siebel Open UI uses the Level field to determine the order it uses to evaluate expressions. It uses the following sequence:

    1. It uses the Level field to determine the order it uses to evaluate group expressions. In this example, it uses the following sequence:

      • Evaluates the Grid group first.

      • Evaluates the Tile group next.

      • Evaluates the Map group last.

    2. It uses the Level field within a group to determine the order it uses to evaluate each subexpression, which is a type of expression that Siebel Open UI displays as part of a group in the Object Expressions list. It displays each subexpression in an indented position after the group expression. In this example, it uses the following sequence to evaluate subexpressions that reside in the Grid group:

      • Evaluates the Desktop expression first.

      • Evaluates the EditList expression next.

      • Evaluates the Grid expression last.

      In this example, Siebel Open UI evaluates all the expressions that reside in the Grid group, and then does one of the following according to the result of this evaluation:

      • All expressions that reside in the Grid group evaluate to true. Siebel Open UI downloads the file that the Files list specifies.

      • Any expression that resides in the Grid group evaluates to false. Siebel Open UI discards the entire Grid group, and then evaluates the Tile group.

  3. Siebel Open UI uses the Files list to identify the files it must download. In this example, it does the following evaluation:

    • If the platform is a desktop, and if the mode is EditList, and if the user chooses Grid, then it downloads the siebel/jqgridrenderer.js file.

    • If the platform is a desktop, and if the mode is EditList, and if the user chooses Tile, then it downloads the siebel/Tilescrollcontainer.js file.

To view an example that allows the user to choose Grid or Tile, see Allowing Users to Change the Applet Visualization.

Start Application with Seeded Manifest Entries

You can use the ManifestSafeLoad component parameter to launch a Siebel application, such as Call Centre, with only Oracle-provided manifest records. These records are seeded records in manifest. To launch the application using this parameter, you have to set the value of the parameter to TRUE. By default, the value is FALSE, which allows the application to launch both custom-configured and seeded records using manifest. You can change the parameter’s value for the application’s object manager (in this case, SCCobjMgr_enu) as follows:

change param ManifestSafeLoad=TRUE for comp <application_object_manager>_<language>
Note: Restart the component after modifying the parameter. You need to change the parameter only for Siebel applications, and not for Web Tools, because the latter always starts with Oracle-provided Manifest records.

Configuring Custom Manifests

This topic describes how to configure the example described in Example of a Completed Manifest Administration. For other examples that configure the manifest to download objects for:

To configure custom manifests

  1. Make sure your custom presentation model or physical renderer uses the Define method:

    1. Use a JavaScript editor to open your custom presentation model or physical renderer.

    2. In the section where you configure Siebel Open UI to do the setup, make sure you use the Define method to identify the presentation model file or the physical renderer file.

      For an example that does this setup, see Example of How Siebel Open UI Identifies the JavaScript Files It Must Download.

  2. Configure the manifest files:

    1. Log in to a Siebel client with administrative privileges.

    2. Navigate to the Administration - Application screen, and then the Manifest Files view.

    3. Verify that the Manifest Files view includes the files that Siebel Open UI must download for your custom deployment.

      For this example, verify that the Manifest Files view includes the following files:

      siebel/listapplet.js
      siebel/jqgridrenderer.js
      

      If the Manifest Files view does not include these files, then add them now. For more information, see Adding Java Script Files to Manifest Administrative Screens.

  3. Configure the UI object:

    1. Navigate to the Administration - Application screen, and then the Manifest Administration view.

    2. In the UI Objects list, specify the following object.

      Field

      Value

      Type

      Applet

      Usage Type

      Physical Renderer

      Name

      Contact List Applet

      For more information, see Fields of the UI Objects List.

  4. Configure the Grid group:

    For more information about how to configure a group, see Adding Group Expressions.

    1. In the Object Expression list, add the following subexpression.

      Field Value

      Group Name

      Leave empty.

      Expression

      Desktop

      Level

      1

      Operator

      Leave empty.

      Web Template Name

      Leave empty.

      For more information, see Fields of the Object Expression List.

    2. Add another subexpression.

      Field Value

      Group Name

      Leave empty.

      Expression

      EditList

      Level

      2

      Operator

      Leave empty.

      Web Template Name

      Leave empty.

    3. Add another subexpression.

      Field Value

      Group Name

      Leave empty.

      Expression

      Grid

      Level

      3

      Operator

      Leave empty.

      Web Template Name

      Leave empty.

    4. Add the following group expression.

      Field Value

      Group Name

      Leave empty.

      Expression

      Grid

      Level

      1

      Operator

      Leave empty.

      Web Template Name

      Leave empty.

    5. Use the Move Up and Move Down buttons to arrange the subexpressions in ascending numeric order according to the value in the Level field. Make sure the Object Expression list displays all subexpressions after the group expression.

    6. Use the Indent and Outdent buttons so that Siebel Open UI displays the subexpressions after and indented from the group expression. The tree in the Inactive Flag field displays this indentation.

    7. In the UI Objects list, query the Name property for the name of the UI object that you are configuring. This query refreshes the Manifest Administration screen so that you can edit the Group Name and Operator fields of the group expression.

    8. In the Object Expressions list, expand the tree that Siebel Open UI displays in the Inactive Flag field.

    9. Set the following fields of the group expression.

      Field Value

      Group Name

      Grid

      Operator

      AND

  5. Specify the files that Siebel Open UI must download for the Grid group:

    1. Make sure the Grid group expression is chosen in the Object Expression list.

    2. In the Files list, click Add.

    3. In the Files dialog box, click Query.

    4. In the Name field, enter the path and file name of the file.

      For example, enter the following value:

      siebel/jqgridrenderer.js
      
    5. Click Go.

      If the Files dialog box does not return the file that your deployment requires, then you must use the Manifest Files view to add this file before you can specify it in the Files list. For more information, see Adding Java Script Files to Manifest Administrative Screens.

    6. Click OK.

  6. Configure the Tile group:

    1. Repeat Step 4, with the following differences:

      • For the group expression, set the Group Name field to Tile and the Level field to 2.

      • For the last subexpression, set the Expression field to Tile.

    2. Repeat Step 5, except add the following file:

      siebel/tilescrollrenderer.js
      
  7. Configure the Map group:

    1. Repeat Step 4, with the following differences:

      • For the group expression, set the Group Name field to Map and the Level field to 3.

      • Add only one subexpression with the Expression field set to Map.

    2. Repeat Step 5, except add the following file:

      siebel/custom/siebelmaprenderer.js
      
  8. In the Object Expression list, use the Move Up, Move Down, Indent, and Outdent buttons until the Object Expression list resembles the configuration in the figure in the topic Overview of Configuring Manifests.

Fields of the UI Objects List

The following table describes the fields of the UI Objects list.

Table Fields of the UI Objects List

Field Description

Inactive Flag

Set to one of the following values:

  • Y. Make the object inactive. Make sure you set the Inactive Flag to Y for any custom object that your deployment does not require.

  • N. Make the object active. Make sure you set the Inactive Flag to N for any custom object that your deployment requires.

The Inactive Flag allows you to configure more than one manifest. You can activate or deactivate each of these configurations during development. You can set the Inactive Flag in the same way for each object that the Manifest Administration view displays.

Type

Choose one of the following values to specify the type of Siebel CRM object that you are customizing:

  • Application

  • View
  • Applet
  • Navigation
  • Toolbar
  • Menu
  • Control

For more information, see How Siebel Open UI Chooses Files If Your Custom Manifest Matches a Predefined Manifest.

Usage Type

Specify how Siebel Open UI must download files. Choose one of the following values:

  • Common. Siebel Open UI downloads the files when it initializes the Siebel application. Siebel Call Center is an example of a Siebel application.

  • Theme. Siebel Open UI downloads only the files it requires to support a theme that you customize. For an example that uses this value, see Customizing the Logo.

  • Presentation Model. Siebel Open UI downloads the files that your custom presentation model requires.

  • Physical Renderer. Siebel Open UI downloads the files that your custom physical renderer requires.

  • Web Template. Siebel Open UI uses ODH according to the Name property of the Web template. You specify this OD content in the Web template in Siebel Tools. For more information, see Identifying the ODH.

For more information, see How Siebel Open UI Chooses Files If Your Custom Manifest Matches a Predefined Manifest.

Name

Enter the name of your custom object. For example, if you set the Type to Applet, then you must specify the value that Siebel Tools displays in the Name property of the applet.

Fields of the Object Expression List

The following table describes the fields of the Object Expression list. You can configure a simple expression, or you can configure a complex expression that includes AND or OR operators, and that can include nested levels. For an example that includes complex expressions, see Configuring Custom Manifests.

Table Fields of the Object Expression List

Field Description

Group Name

If the record that you are adding to the Object Expressions list is part of a group of two or more expressions, and if this record is the group expression, then enter a value in the Group Name field and leave the Expression field empty.

The Object Expressions list is a hierarchical list. You can use it to specify complex expressions that you enter as more than one record in this list.

You must add more than one record and indent at least one of them before you can enter a group name. For more information about how to do this work, see Adding Group Expressions.

Expression

If the record that you are adding to the Object Expressions list is:

  • Not a group expression. Set a value in the Expression field and leave the Group Name field empty.

  • A group expression. Leave the Expression field empty and enter a value in the Group Name field.

If the Expression list does not include the expression that your deployment requires, then you must add a custom expression. For more information, see Adding Custom Manifest Expressions.

Level

Enter a number to determine the order that Siebel Open UI uses to evaluate expressions that the Object Expression list contains. Siebel Open UI evaluates these expressions in ascending, numeric order according to the values that the Level field contains. If the Type field in the UI Objects list:

  • Is Application, then Siebel Open UI evaluates every expression. It downloads each file that the Files list specifies for each expression that it evaluates to true.

  • Is not Application, and if Siebel Open UI evaluates an expression to true, then it does the following:

    • Downloads the file that the Files list specifies for this expression

    • Does not process any expression that exists further down in the order

    • Does not download any other files

Operator

If the record that you are adding to the Object Expressions list is a group expression, then you must specify the logical operator that Siebel Open UI uses to combine the subexpressions that the group contains. You can use one of the following values:

  • AND. Specifies to combine subexpressions. If you specify AND, then Siebel Open UI downloads files only if it evaluates every subexpression in the group to true.

  • OR. Specifies to consider individually each subexpression that resides in the group. If you specify OR, then Siebel Open UI downloads files according to the first subexpression that it evaluates to true.

If the record that you are adding to the Object Expressions list is not a group expression, or if it does not reside first in the hierarchy, then leave the Operator field empty.

Web Template Name

If you set the Usage Type field in the UI Objects list to Web Template, then you must specify the name of the Siebel CRM Web template file in the Web Template Name field. To identify this file name, see Identifying the ODH.

Adding Group Expressions

You must use the sequence that this topic describes when you add a group expression. For an example that uses this sequence, see Configuring Custom Manifests. For more information about group expressions and subexpressions, see Example of a Completed Manifest Administration.

To add group expressions
  1. Navigate to the Administration - Application screen, and then the Manifest Administration view.

  2. In the UI Objects list, locate the UI object that you must modify.

  3. In the Object Expression list, add the subexpressions.

  4. Add the group expression. Leave the Group and Operator fields empty.

  5. Use the Move Up and Move Down buttons to arrange the subexpressions in ascending numeric order according to the value in the Level field. Make sure the Object Expression list displays all subexpressions after the group expression.

  6. Use the Indent and Outdent buttons so that Siebel Open UI displays the subexpressions after and indented from the group expression. The tree in the Inactive Flag field displays this indentation.

  7. In the UI Objects list, query the Name property for the name of the UI object that you are configuring. This query refreshes the Manifest Administration screen so that you can edit the Group Name and Operator fields of the group expression.

  8. In the Object Expressions list, expand the tree that Siebel Open UI displays in the Inactive Flag field.

  9. Set the values for the Group Name field and the Operator field of the group expression.

How Siebel Open UI Chooses Files If Your Custom Manifest Matches a Predefined Manifest

If the values that you specify in the Type, Usage Type, and Name fields of the UI Objects list are identical to the values that a predefined UI object specifies, then Siebel Open UI uses your custom manifest. For example, Siebel Open UI comes predefined with a UI Object record with the Type set to Applet, the Usage Type set to Physical Renderer, and the Name set to Contact List Applet. To override this configuration, you must do the following work:

  • Create a new record in the UI Objects list that contains the same values in the Type, Usage Type, and Name fields that the predefined record contains.

  • Add a new record in the Object Expression list that evaluates to true.

  • Add a new record in the Files list for the object expression that evaluates to true.

The only exception to this rule occurs in the following situation:

  • You set the Type to Application.

  • You set the Usage Type to Common.

  • A winning expression exists in your customization. A winning expression is an expression that Siebel Open UI evaluates to true, and that Siebel Open UI then uses to identify the files it must download according to the configuration that the Manifest Administration view specifies.

In this situation, Siebel Open UI downloads the files that:

  • The predefined manifest configuration specifies

  • The winning expression of your custom manifest configuration specifies

The following table describes how Siebel Open UI chooses files if your manifest configuration matches the predefined manifest configuration for a UI object. The Configuration column describes values that the UI Objects list of the Manifest Administration screen contains.

Table How Siebel Open UI Chooses Files If Your Custom Manifest Matches the Predefined Manifest

Configuration Predefined Configuration Exists Custom Configuration Exists Result

Type is Application and Usage Type is Common

Yes

No

Siebel Open UI downloads files according to the winning predefined expressions.

Type is Application and Usage Type is Common

Yes

Yes

Siebel Open UI downloads files according to the winning predefined expression and the winning custom expressions.

Usage Type is not Common

Yes

No

Siebel Open UI downloads files according to the first predefined expression that it evaluates to true.

If more than one expression exists, then it uses the level to determine the sequence it uses to evaluate these expressions.

Usage Type is not Common

Yes

Yes

Siebel Open UI downloads files according to the first custom expression that it evaluates to true.

If more than one expression exists, then it uses the level to determine the sequence it uses to evaluate these expressions.

If Siebel Open UI does not evaluate any custom expression to true, then it uses a predefined expression for this object.

Identifying the ODH

This topic describes how to identify the ODH that a Web template uses.

To identify the Web template file name
  1. Open Siebel Tools.

    For more information, see Using Siebel Tools.

  2. In the Object Explorer, click Web Template.

  3. In the Web Templates list, locate the object definition for the Web template.

    For example, if you entered Applet Form Grid Layout in the Name field in the UI Objects list, then query the Name property in the Web Templates list for Applet Form Grid Layout.

    The Definition Column lists the Object Definition for the queried Web template.

    For example, Siebel Open UI uses the CCAppletFormGridLayout Web template for the Applet Form Grid Layout Web template.

Adding Custom Manifest Expressions

This topic describes how to add a custom manifest expression.

To add custom manifest expressions

  1. Log in to a Siebel client with administrative privileges.

  2. Navigate to the Administration - Application screen, and then the Manifest Expressions view.

  3. In the Expressions list, add the following expression.

    Field Value

    Name

    Enter text that describes the expression. For example, enter the following value:

    Desktop
    

    Siebel Open UI uses this value as an abbreviation for the expression that it displays in the Expression field in the Object Expression list in the Manifest Administration screen. It uses this abbreviation only to improve readability of the Object Expression list.

    Expression

    Enter an expression. For example, to apply the expression according to the:

    • Platform, use the following expression:

    GetProfileAttr("Platform Name") = 'Desktop'
    

    This example applies the expression for desktop platforms.

    • User position, use the following expression:

    GetProfileAttr("Primary Position Type") = "Sales Representative"
    

    This example applies the expression for the Sales Representative position.

    Siebel Open UI uses this value when it evaluates expressions that reside in the Object Expression list. For more information, see GetProfileAttr Method.

Using Temporary Manifest Expressions During Development

It is recommended that you configure a temporary manifest expression that makes the manifest specific to a single user. This configuration allows you to test and troubleshoot the manifest configuration, if necessary.

To use temporary manifest expressions during development
  1. Configure a manifest.

    For more information, see Configuring Custom Manifests.

  2. In the Expressions list, add an expression that configures the manifest for a single user.

    For example:

    Name Expression
    CCHENG
    
    GetProfileAttr("Login Name") = 'CCHENG'
    
  3. Log out of the client, and then log back in to the client using the ID that you specified in Step 2.

    If you encounter an error during the log in, or if the client stops responding, then do the following:

    1. Close the client session.

    2. Log in with a user ID that is different from the ID that you specified in Step 2.

    3. Troubleshoot the manifest configuration error.

      For example, assume you configure a manifest that references a custom file in the siebel/custom folder, but you forget to add this custom file to this folder. If you attempt to log in to the client with this configuration, then the client might stop responding, and you might not be able to examine the manifest configuration. If you configure a temporary expression that is specific to a single user, then you can log in as a different user and troubleshoot the manifest configuration.

  4. If necessary, fix the manifest configuration.

  5. Remove the expression that you added in Step 2.

Adding JavaScript Files to Manifest Administrative Screens

This topic describes how to add a JavaScript file to the manifest administrative screens.

To add JavaScript files to manifest administrative screens

  1. Log in to a Siebel client with administrative privileges.

  2. Navigate to the Administration - Application screen, and then the Manifest Files view.

  3. In the Files list, add a new record for each JavaScript file that you must add.

    Make sure you include the path. For example, to add the mycustomrenderer.js file, you add the following value:

    custom/mycustomrenderer.js
    

    You can now add this file in the Files list in the Manifest Administration view. For more information about how to do this, see Step 5 in the topic Configuring Manifests.

Configuring Manifest for Context Renderers

A context renderer can be configured through manifest for View or Applet against the Physical Renderer type.

To configure manifest for context renderers

  1. Log in to a Siebel client with administrative privileges.

  2. Navigate to the Administration - Application screen, then the Manifest Administration view.

  3. In the UI Objects list, query the Name property for the name of the UI object that you are configuring.

  4. In the Object Expressions list, validate if any files are listed against the expression for which you are configuring the CR. If there are no files configured, add the physical renderer file as the first entry in the Files applet.

  5. In the Files list, select the required CR file name and add it.

  6. Use the Sequence field to set the sequence value to be used for determining the order of CR execution.

    Note: You must add the first file entry for physical renderer (phyrenderer.js, jqgridrenderer.js or any custom renderer) with the sequence as 1, and then configure context renderer using the next sequence.
  7. To add the physical renderer and context renderer files:

    1. In the Files list, click Add.

    2. In the Files dialog box, click Query.

    3. In the Name field, enter the path and file name of the required file.

    4. Click Go.

Configuring Multiple Tab Browsing

Siebel supports accessing the same applications over multiple tabs of the same browser session. By default, multi-tab browsing is disabled. Each tab access to Siebel interactive application creates a new Siebel session. Multi-tab browsing minimizes the impact on the server by providing a configurable option to control the maximum number of tabbed browser sessions for an interactive application in a given browser window.

Note: It is recommended that administrators should consider the business requirements of their organizations before enabling multiple browser tabs and should limit the Maximum Possible Tabbed Sessions field value to minimize any adverse effect on scalability. Accessing an additional tab than the value configured for the Maximum Possible Tabbed Sessions field generates a session warning message.

To configure the Multi-Tab browsing, perform the following tasks:

  1. Setting Server Parameter to Enable Multi-Tab Access

  2. Configuring Application Interface Profile Parameter to Limit the Number of Browser Tabs

Setting Server Parameter to Enable Multi-Tab Access

To set the server parameter for enabling Multi-Tab access, perform the following steps:

  1. Log in to a Siebel client with administrative privileges.

  2. Navigate to the Administration - Server Configuration screen, and then the Servers view.

  3. In the Siebel Servers list, choose a Siebel Server.

  4. Click the Components view tab.

  5. In the Components list, select the required Application Object Manager. For example, Call Center Object Manager (ENU).

  6. Select Parameters from the drop-down list above the Component Event Configuration section and click the Hidden button.

  7. In the Parameter field, perform a case-sensitive search for the EnableMultiTab parameter.

  8. In the Value on Restart field, enter True.

  9. Restart the Siebel server.

Configuring Application Interface Profile Parameter to Limit the Number of Browser Tabs

To set the Application Interface profile parameter to limit the number of browser tabs, perform the following steps:

  1. Log in to Siebel Management Console.

  2. Select the required Application Interface profile.

  3. Select the Applications tab and expand the Enhanced Authentication section of the selected application.

  4. In the Maximum Possible Tabbed Sessions field, enter a value to limit the number of browser tabs. For example, 2, if you want to allow only two browser tabs. By default, the value for Maximum Possible Tabbed Sessions field is set to 1.

    Note: This parameter is effective only when the EnableMultiTab server parameter is set to True for the specified Application Object Manager.
  5. Save the profile.

Configuring Smartphone UX

Siebel Open UI supports an enhanced UX for Smartphone (iOS and Android) devices for mobile applications. With this feature, Siebel Open UI uses a specialized PHONE theme for smartphone devices, where list applets are transformed to Tile visualization mode with infinite scrolling navigation, and navigation defaults to Side Menu. The enhance Smartphone UX also employs some specialized out-of-the-box context renderers to optimize the layout on the client to ensure the optimal usage of available real estate.

You enable the Smartphone UX for mobile applications bye setting the component parameter AutoTileType to PHONE as follows:

change param AutoTileType=PHONE for comp <application_object_manager>_<language>

For example, to enable Smartphone UX for Service Mobile, modify the component parameter as follows:

change param AutoTileType=PHONE for comp ServiceMObjMgr_Enu
Restart the component after modifying the component parameter to see the enhanced look and feel in Smartphone devices.
Note: For desktop or tablet devices, modifying the AutoTileType component parameter will not change the look and feel of the application.

Guidelines for Customizing Smartphone UX

  • Smartphone UX uses a predefined theme, specially designed for mobile form factor. For information on customizing themes, see Customizing Themes. Make sure to add Smartphone as the Manifest expression value when configuring a custom theme in the Manifest Administration view.

  • Smartphone UX uses the Side menu navigation type by default and its predefined theme provides CSS definition for the Side menu.

  • Smartphone UX uses the Auto Tile feature to display List Applet in Tile visualization mode. For more information, see Auto Tile Visualization Feature. To customize the list of fields in Tile, see Customizing the Tile Content.

  • If Tile visualization mode is not required for any List Applet in Smartphone UX, it can be turned off using the Applet user property. For more information, see Auto Tile Behavior.

  • Smartphone UX uses context renderer to display accordions for Applets in a View. In addition, it uses context renderer for functionality like in-line Tile Editing capability. If required, customized context renderer can be implemented for customization. To deploy Context Renderer only for Smartphone UX mode, configure Smartphone as the Manifest expression when configuring Physical Renderer/Context Renderer in Manifest Administration View. For more information, see About Context Renderers, Configuring Custom Manifests, and Configuring Manifest for Context Renderers.

About Preferences

Siebel Tools has preferences that control the appearance and behavior of user interface elements. To set these preferences, navigate to Administration-Application, and then System Preferences.

The following table describes some of the preferences available.

Table Siebel Open UI Preferences

System Preference Name Default Value Description

Enable Responsive Label

Y

Enables Smart Labels. Input fields qualified for responsiveness start showing a label as soon as any input character is typed in them. These fields must have a input value,

Enable Elastic Grid

Y

Enables Elastic Grid. When enabled, a list applet’s height is reduced to the height required for the number of records being displayed in the UI.

Busy Cursor Timeout

30

Controls the maximum time the cursor shows as busy. The default value is 30 seconds and is also the minimum value.

The Busy Cursor Timeout preference provides a way to customize the maximum timeout of the application based on the customer process and usage. This system preference does not change the busy cursor behavior. It provides a way to customize the hourglass timing. Busy Cursor Timeout can be interrupted by other processes that also have timeouts, such as Message Bar interval, Portlet session timeout, or any custom implementation that does a polled server call at regular intervals. The Busy Cursor Timeout value should be less than the timeout values of these processes.

The end of the busy cursor period can indicate one of the following events:

  1. A process may take more time than the maximum Busy Cursor Timeout value and the maximum time has been reached.

  2. The process has completed.

  3. The process has been interrupted by another module.

Starting with look ahead

N

Controls the autocomplete logic in drop-down menus based on the value of the drop-down input field. When set to N (or False) the look ahead logic is "Contains". When set to Y (or True), the look ahead logic is "Starting with". For example, when set to N, and the value of the input field is tom, then the drop-down menu displays values such as tomb, atomic, and custom. When set to Y, the drop-down menu displays only tomb from the same set of data.