Notifications

5 views

Description

This is not something we have provided OOB but it can be achieved by cloning the OOB widget and making some minor changes to its code. 

This is customization and is not directly supported by ServiceNow. Also, this change may cause issues on the upgrade because the OOB widget changes will not be applied to your custom widget. 

Cause

1) You need to change the code which checks if the VA is enabled to return false instead of checking the plugin.

2) You also need to edit the server script to tell the chat client to go directly to a live agent by adding a URL parameter "sysparm_live_agent_only=true" to any instance of "url_params" within the server script. This will get passed into the chat client and then it will skip the VA topics.

Resolution

1) Edit this line:

"data.isVAActive = new GlidePluginManager().isActive("com.sn_hr_virtual_agent")"

To be something liek this:

data.isVAActive = false;

 

2) Add the "sysparm_live_agent_only=true" string to the url_params. 


For example, you will need to edit this code:
url_params = "sysparm_liveagent_queue="+queueId;
if (input.startNewConversation) {
url_params = "sysparm_liveagent_queue="+queueId+"&sysparm_skip_load_history=true";

And also this line:
if (data.isHrCoreActive) {
url_params = "sysparm_liveagent_queue=fde232209f22120047a2d126c42e70ab";

Additional Information

How to clone a widget

Article Information

Last Updated:2019-11-22 09:08:53
Published:2019-11-22