Metric to calculate Incident Assigned to agent in state In Progress

David Fiedler
Tera Contributor

Hello,

I need to create a metric to measure how long an incident has been assigned to a specific agent, but only when the incident state is "In Progress." For example, if the agent changes the state to "On Hold," the time should no longer be counted. Is it possible to achieve this with metrics?

Thank you!

3 REPLIES 3

Najmuddin Mohd
Mega Sage

Hi @David Fiedler ,

There is One Plugin SLA Breakdown by Assignment. It may help you.

Check the following link,
https://www.youtube.com/watch?v=eKLWsaEz3rs


You can achieve how long the Incidents are there with Every user.


If the above information helps you, Kindly mark it as Helpful and Accept the solution.
Regards,
Najmuddin.

Hello, 

thank you but would prefer in this case to use metrics. As I mainly need to find out for how long ticket is in active state and assigned to agent, counting time where incident is in progress and assign to field is not empty would also work for me. 

johnfeist
Mega Sage
Mega Sage

Hi David,

Here's how I would handle it, not fancy but effective.

  • Add two columns to incident, something like In Progress Start, as a date time and In Progress Duration.  Add In progress duration to the incident form.
  • Create a business rule that responds to changes in incident state.  When the state changes from In Progress to anything else clear In Progress Start.  When it changes to In Progress put the current date time into In Progress Start.
  • Create a second business rule, as type = display.  Have that do the calculation for how long and put it on the scratch pad.  Use something like -1 if it is not In Progress
  • Add a client script (on load) have it check the scratch pad for how long.  If the value is not -1, then you can  your client script will make IN Progress Duration visible and populate with the value from the scratchpad.

I know this sounds a little complex but it's actually pretty straight forward.  Please let me know if you need clarification on any part of it.

Hope that helps.

:{)

Helpful and Correct tags are appreciated and help others to find information faster