Genesys CTI User Forum
Genesys CTI User Forum => Genesys CTI Technical Discussion => Topic started by: ku on July 18, 2018, 05:35:45 AM
-
Hi guys
I have a problem with CCP.
I want to show the reason for notready by agent and use "Formula".
But sixth line always error,please help.
result.Text = GetUserData();
function GetUserData()
{
var r = "";
r += state.Status;
for(var e = new Enumerator(state.CallData.Filter("Key=AuxReason")); !e.atEnd(); e.moveNext())
{ if (e.item().Key=='AuxReason')
data = e.item().Value;
}
return r;
}
Thanks
-
What version of CCPulse?
Sent from my Redmi Note 3 using Tapatalk
-
Hi vmc
CCPulse version is 8.1.100.40.
-
Below is how I have the code setup for the formula stat, it's an if/else statement. This will differ from how/where the stats are created, but it works for my organization and shows the Not Ready disposition that is in use at the current time.
if (ccpulse.group("Current NR Status").statistic("Not Ready") > 0) {"Not Ready"}
else if (ccpulse.group("Current NR Status").Break >0) {"Break"}
else if (ccpulse.group("Current NR Status").Chats >0) {"Chats"}
else if (ccpulse.group("Current NR Status").Lunch >0) {"Lunch"}
else if (ccpulse.group("Current NR Status").statistic("Management Session") >0) {"Management Session"}
else if (ccpulse.group("Current NR Status").Meeting >0) {"Meeting"}
else if (ccpulse.group("Current NR Status").Paperwork >0) {"Paperwork"}
else if (ccpulse.group("Current NR Status").Projects >0) {"Projects"}
else if (ccpulse.group("Current NR Status").statistic("Team Meeting") >0) {"Team Meeting"}
else if (ccpulse.group("Current NR Status").Training >0) {"Training"}
else if (ccpulse.group("Current NR Status").statistic("Wrap-Up") >0) {"Wrap-Up"}
else if (ccpulse.group("Current NR Status").statistic("Wrap-Up Escalation") >0) {"Wrap-Up Escalation"}
else if (ccpulse.group("Current NR Status").statistic("Manual") >0) {"Manual"}
-
pdavid's way is how I've done it in the past but your original formula should work in theory as well. Did you create the filter on stat server?
I know that calldata stuff changed between certain versions (check the CCPulse release notes).
Sent from my Redmi Note 3 using Tapatalk