Although
a piece of logic to be executed could be achieved through a button as well as
Method Menu Item, the approach in configuring both is at variance.
Steps
to configure Applet Method Menu Item:
- Create a command object and associate a method (Either a Business Service method or Custom method)
- Associate the command to the Applet Method Menu Item.
- Provide a user property CanInvokeMethod to enable the invocation of the same.
- Define the logic behind the method at Applet or BS that is associated to the command. These two approaches have been mentioned below in detail.
Configuring
the logic through Browser Script of a Business Service:
- · Create a command with Target Property- Browser, give the BS Name and the method Name to be executed in the Business Service and Method Properties.
- · Browser value in the Target Property signifies that the logic is implemented in the browser script of the Business Service Method Specified.
- · Create user property at applet level with CanInvokeMethod: Method Name as TRUE (Method Name should be same as BS Method Name mentioned in the Command Object).
- · Logic that is to be implemented should be written in the browser script of the BS Method.
Configuring
the logic through Browser Script of an Applet:
- · Create a command with Target Property- Browser Applet, give the Method Name to be executed in the Method property of the command.
- · Browser Applet value in the Target Property signifies that the logic is implemented in the browser script of the Applet.
- · Create user property at applet level with CanInvokeMethod: Method Name as TRUE.
- · Ensure that the logic is implemented at the browser script of the applet with same method name that is mentioned in the Method property of the command object created.
Note:
Browser script had to be used instead of server script
because the Command Object handles the same as mentioned below.
In the Command Object, Target Property value has an option
called “Server”, when we try to enclose the logic in a
Custom Method instead of using a Business Service Method, the method handler is
initially the applet class to which the applet belongs. Siebel CRM
re targets it successively up through the applet class hierarchy to CSSSWEFrame.
If still not handled, then Siebel CRM re targets to the business component class
of the business component that the applet references, and successively upwards
through the business component class hierarchy to CSSBusComp.
Thanks for sharing this informative post here.
ReplyDelete