Examples of Use
There are three methods of use of the Push Notification Service:
- Send a message
The 'pushMessage()' action invokes a message box with given message on all target web clients.
Example:
VM.getPushService().pushMessage("Test message to all users", "*")
- Launch a workflow
The 'pushWorkflow()' action starts a workflow with given parameters on all target web clients.
Example:
oWflParams = VM.createMap()
oWflParams.put("objecttype", "Department")
VM.getPushService().pushWorkflow("PushServiceOpenCatalog", oWflParams, "LIA,ORS@USU.CZ".split
(','))
- CTI events
The 'pushCTIConnectedEvent' action gives the selected users information about the CTI event.
Note that in all three cases, users are defined by a userId or userId with domain (e.g. userId@domain). If all currently connected users must be informed, use the asterisk character [*]. You can insert a list of strings to inform more users about the event.
|