Support Article

Calling UpdateStatus via an agent doesn't fully update the case

SA-36650

Summary



The developers have built a flow which is designed to update a child case to Resolved-Completed through an agent.

After the agent has processed the activity to set the child case to Resolved-Completed the history does included entries to suggest the update had happened and the parent case pyCoveredCountOpen gets decremented, however the child case status still appears to be "New".

Subsequently when the administrator tries to make a second call to UpdateStatus but this time through a UI Action, this returns the error message below and they are unable to resolve the case.

Error Messages



** The cover open count is incorrect; it is -1


Steps to Reproduce



1. Create an activity that includes a call to UpdateStatus, setting the status to Resolved-Completed.
2. Create an agent to call the above activity.
3. Ensure that the agent is currently stopped.
4. Define a parent case and child case.
5. For the child case; Create flow which includes a shape that will queue a job for the above agent.
6. Create a parent case case and a child case
7. Process the child case until it reaches the shape which will call the agent.
8. Close both parent and child case tabs in the UI.
9. In SMA start the agent.
10. In the UI, reopen the child case.
11. Observe that the audit notes includes recent entries saying the status has changed to Resolved-Completed, but the child case still has an open status.
12. Reopen the parent case and open the clipboard on pyWorkPage.
13. Observe that the pyCoveredCountOpen is 0.


Root Cause



When UpdateStatus is called though the UI this will cause the case to be updated.

However, when called via a background activity, such as an agent, the work object itself won't be updated automatically.

Resolution



When calling UpdateStatus through a background activity it is imperative that user must also make a call to Obj-Save in order to fully update the work object.

Published April 18, 2017 - Updated May 9, 2017


80% found this useful

Have a question? Get answers now.

Visit the Collaboration Center to ask questions, engage in discussions, share ideas, and help others.