Commit Graph
2 Commits
Author SHA1 Message Date
Samuel Degueldre 37aca4a38e [FIX] im_livechat: add missing dependencies to manifest
The dependencies of the public_root module were recently updated, but
the manifest of im_livechat was not, causing it to fail to load. This
commit adds those missing dependencies to the manifest.

This commit also adds a test that checks that all modules are properly
loaded on the support page, since this has been broken on multiple
occasions while changing the dependencies or the path of some of the
modules this page needs to work.

closes odoo/odoo#74756

Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2021-08-06 10:15:23 +00:00
Aurélien Warnon 9b867cd12d [IMP] im_livechat: improve random assignation of conversations
Task #1919871

Purpose
=======
The method 'get_mail_channel' in the 'im_livechat.channel' model used a simple random.choice in
the available users to select the operator.

It was improved to select the operator that has the lowest number of active livechats. If multiple
operators share the same number (lowest) of active livechats, it selects randomly between those.

A livechat is considered 'active' if it has at least one message within the last hour.

Spec
=======
The assignation method should always give the new conversation to the operator who
has the less active conversation.

If two operators have the same amout of active conversation, it should chose one of
them randomly.
2019-04-01 07:03:11 +00:00