Skip to content
This repository has been archived by the owner on Jun 30, 2022. It is now read-only.

[Livechat] Non available Livechat forwarded to different Department #404

Open
twintime opened this issue Feb 20, 2019 · 1 comment
Open
Assignees

Comments

@twintime
Copy link

Description:

We've created several Departments for the Livechat. Let's call them X, Y and Z.
For each of these Departments we set Show on registration page to no.

Afterwards, we created three embedded seperate Livechats Windows using the Function:

<script type="text/javascript">
(function(w, d, s, u) {
	w.RocketChat = function(c) { w.RocketChat._.push(c) }; w.RocketChat._ = []; w.RocketChat.url = u;
	var h = d.getElementsByTagName(s)[0], j = d.createElement(s);
	j.async = true; j.src = 'http://ROCKETCHAT-URL/packages/rocketchat_livechat/assets/rocketchat-livechat.min.js?_=201702160944';
	h.parentNode.insertBefore(j, h);
})(window, document, 'script', 'http://ROCKETCHAT-URL/livechat');
RocketChat(function() {
    this.setDepartment('DEPARTMENT');
});
</script>

and set under Appearance "Livechat offline--> Display Offline Form: False" which is working fine.

The problem is that as soon as Department X is Offline and Y goes Online, the Chat Window is shown again and therefore the Chats are forwarded, which is not the desired outcome.

Steps to reproduce:

Open Livechat Page for Department X when X isn't Online
Livechat Window Appears
User fills in their Data
Livechat will be forwarded to Department Y

Expected behavior:

Show no Livechat Window when the actual Department is Offline and another one is Online.

Actual behavior:

Livechat Window for Department X comes up when Y or Z are Online

Server Setup Information:

  • Version of Rocket.Chat Server: 0.74.0
  • Operating System: Ubuntu 16.04 LTS
  • Deployment Method: tar
  • Number of Running Instances: 1
  • DB Replicaset Oplog: Disabled
  • NodeJS Version: 8.11.3
  • MongoDB Version: 3.4.19

Additional context

Relevant logs:

@renatobecker-zz
Copy link
Contributor

Hi @twintime, the current behavior regarding the livechat status(online/offline) does not consider the status of agents related to the department defined with thesetDepartment method, but it considers if there is at least one agent online when the widget is loaded.
We're aware that we need to improve this behavior and we have plans to start working on this demand ASAP, so I suggest you to keep tracking our next steps and thank you for helping us to improve our Livechat solution.

Regards.

@renatobecker renatobecker transferred this issue from RocketChat/Rocket.Chat May 5, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants