[SalesForce] Liveagent in Console: Unsaved Changes Prompt

Here's an shot of my Service Cloud Console right after a new Liveagent chat has begun:

Console Screenshot

There are three subtabs under the main Chat tab: Details, Jason Clark (contact record, opened via Liveagent API), and 00001273 (case, created and opened via Liveagent API). I have selected the Details tab to demonstrate my question.

First: Note that the primary Chat tab and the Details tab both have an asterisk (*) denoting unsaved changes. In the case of the Details tab, it's referring to the new Details record. As the Related Entities fields cannot be pre-populated (at least, without a pre-chat window, which we are not using), I don't need this subtab to be in edit mode. Is there a way to auto-save this subtab?

Second: Even if I click save, the primary Chat tab continues to show the asterisk, and attempting to close the primary chat tab prompts, "Unsaved Changes – Save your changes (Save/Don't Save/Cancel)". I can't find what changes this is referring to, unless it is the chat transcript – that isn't saved to the database until the chat tab is closed. But regardless of whether I click Save or Don't Save, the transcript is always saved (which is good). What 'unsaved change' is causing this prompt? And is it possible to make the chat transcript get saved as soon as the rep or the customer end the chat?

Best Answer

As you've correctly guessed, the related entities section being in edit mode is what's triggering the save dialog. There is a second condition under which the tab is considered unsaved - when the chat is in progress. If you Save the related entities and end the chat (using the End Chat button), you won't see that prompt.

As far as not needing those fields go, the Spring '14 release notes include this line:

Starting in Spring ’14, the Related Entities panel in the details tab isn’t available for new Live Agent customers. Existing customers will continue to have access to the Related Entities panel.

I'm not sure, but you may be able to contact support to have this changed for an existing organization as well.

Finally, to your question about auto-saving - the chat transcript is saved when the agent closes the chat or disconnects from Live Agent. You could potentially use the service cloud console integration toolkit to listen for the chat end event, and close the tab.

Related Topic