diff --git a/addons/im_livechat/report/im_livechat_report_channel_views.xml b/addons/im_livechat/report/im_livechat_report_channel_views.xml
index 2ec89a1874d..573df5df3b3 100644
--- a/addons/im_livechat/report/im_livechat_report_channel_views.xml
+++ b/addons/im_livechat/report/im_livechat_report_channel_views.xml
@@ -8,8 +8,9 @@
-
-
+
+
+
@@ -20,7 +21,9 @@
-
+
+
+
@@ -55,7 +58,7 @@
Session Statistics
im_livechat.report.channel
graph,pivot
- {"search_default_last_week":1}
+ {"search_default_last_week":1, "group_by": "start_date:day"}
Livechat Support Channel Statistics allows you to easily check and analyse your company livechat session performance. Extract information about the missed sessions, the audience, the duration of a session, etc.
diff --git a/addons/im_livechat/report/im_livechat_report_operator.py b/addons/im_livechat/report/im_livechat_report_operator.py
index 6a39e996297..99dbaa41726 100644
--- a/addons/im_livechat/report/im_livechat_report_operator.py
+++ b/addons/im_livechat/report/im_livechat_report_operator.py
@@ -19,6 +19,7 @@ class ImLivechatReportOperator(models.Model):
start_date = fields.Datetime('Start Date of session', readonly=True)
time_to_answer = fields.Float('Time to answer', digits=(16, 2), readonly=True, group_operator="avg", help="Average time to give the first answer to the visitor")
duration = fields.Float('Average duration', digits=(16, 2), readonly=True, group_operator="avg", help="Duration of the conversation (in seconds)")
+ rating = fields.Float('Average rating', readonly=True, group_operator="avg", help="Average rating given by the visitor")
def init(self):
# Note : start_date_hour must be remove when the read_group will allow grouping on the hour of a datetime. Don't forget to change the view !
@@ -32,6 +33,7 @@ class ImLivechatReportOperator(models.Model):
COUNT(DISTINCT C.id) AS nbr_channel,
C.id AS channel_id,
C.create_date AS start_date,
+ C.rating_last_value as rating,
EXTRACT('epoch' FROM MAX(M.create_date) - MIN(M.create_date)) AS duration,
EXTRACT('epoch' FROM MIN(MO.create_date) - MIN(M.create_date)) AS time_to_answer
FROM discuss_channel C
diff --git a/addons/im_livechat/report/im_livechat_report_operator_views.xml b/addons/im_livechat/report/im_livechat_report_operator_views.xml
index 20abf78312e..75dc2488242 100644
--- a/addons/im_livechat/report/im_livechat_report_operator_views.xml
+++ b/addons/im_livechat/report/im_livechat_report_operator_views.xml
@@ -35,6 +35,10 @@
+
+
@@ -51,7 +55,7 @@
Operator Analysis
im_livechat.report.operator
graph,pivot
- {"search_default_last_week":1}
+ {"search_default_last_month":1}
Livechat Support Channel Statistics allows you to easily check and analyse your company livechat session performance. Extract information about the missed sessions, the audience, the duration of a session, etc.