Interaction Record "Handling Duration" is empty for walkup experience

Ceci Looi
Tera Contributor

What is "Handling Duration" for interactions record. The information is not showing from the Interactions table. How do I fix this? Thanks.

find_real_file.png

2 ACCEPTED SOLUTIONS

Musab Rasheed
Tera Sage
Tera Sage

Hello,

Basically it calculates time from Chat assigned to agent till chat moves to complete state, I see this is working fine in my instance.

find_real_file.png

I see below BR is controlling this

https://instance/sys_script.do?sys_id=b580ab65c72610100c2c770bf4c26023&sysparm_record_target=sys_script&sysparm_record_row=1&sysparm_record_rows=1&sysparm_record_list=scriptCONTAINShandling_duration%5EORDERBYDESCsys_updated_on

If you don't see BR here is how you can configure

find_real_file.png

Script :

(function executeRule(current, previous /*null when async*/) {
	if(current.isActionAborted() || current.live_handoff_time.nil() || current.wait_time.nil())
		return;

	var totalDuration = GlideDateTime.subtract(current.live_handoff_time.getGlideObject(), new GlideDateTime());
	var waitDuration = new GlideDuration(current.wait_time.getGlideObject().getNumericValue());
	var handlingDuration = totalDuration.subtract(waitDuration);
	current.handling_duration = handlingDuration;
})(current, previous);

Please hit like and mark my response as correct if that helps

Regards

Please hit like and mark my response as correct if that helps
Regards,
Musab

View solution in original post

Musab Rasheed
Tera Sage
Tera Sage

Hello,

If you are fine with my response, Please hit like and mark my response as correct if that helps.

Regards

Please hit like and mark my response as correct if that helps
Regards,
Musab

View solution in original post

4 REPLIES 4

Musab Rasheed
Tera Sage
Tera Sage

Hello,

Basically it calculates time from Chat assigned to agent till chat moves to complete state, I see this is working fine in my instance.

find_real_file.png

I see below BR is controlling this

https://instance/sys_script.do?sys_id=b580ab65c72610100c2c770bf4c26023&sysparm_record_target=sys_script&sysparm_record_row=1&sysparm_record_rows=1&sysparm_record_list=scriptCONTAINShandling_duration%5EORDERBYDESCsys_updated_on

If you don't see BR here is how you can configure

find_real_file.png

Script :

(function executeRule(current, previous /*null when async*/) {
	if(current.isActionAborted() || current.live_handoff_time.nil() || current.wait_time.nil())
		return;

	var totalDuration = GlideDateTime.subtract(current.live_handoff_time.getGlideObject(), new GlideDateTime());
	var waitDuration = new GlideDuration(current.wait_time.getGlideObject().getNumericValue());
	var handlingDuration = totalDuration.subtract(waitDuration);
	current.handling_duration = handlingDuration;
})(current, previous);

Please hit like and mark my response as correct if that helps

Regards

Please hit like and mark my response as correct if that helps
Regards,
Musab

Musab, will the contact type makes a different. I am using contact type = "walk-up" instead. I am looking for a way to calculate the Interaction record from time it is Assigned until Completion.

No, that's should not affect but make sure 'Agent chat' checkbox is true, I hope you found OOB BR in your instance as well ? if yes then just compare conditions, it should work

Please hit like and mark my response as correct if that helps

Regards

Please hit like and mark my response as correct if that helps
Regards,
Musab

Musab Rasheed
Tera Sage
Tera Sage

Hello,

If you are fine with my response, Please hit like and mark my response as correct if that helps.

Regards

Please hit like and mark my response as correct if that helps
Regards,
Musab