[FIX] calendar: fix archive ribbon on private event

When the event is private and some other user going to
see the event at that time it was going to display the
archived ribbon because the active field was not in the list
of public fields(readable field).

so added an active field to the readable list so it will display the
propper archive ribbon on a private event.

Task-2144553

closes odoo/odoo#41589

Closes: #41157
X-original-commit: c1b89567ca3fdd6f4004389aad345ad3e52248c3
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
This commit is contained in:
Prakash Prajapati
2019-12-03 06:45:10 +00:00
parent 9ab4f99db3
commit 824b6cf02e
+1 -1
View File
@@ -1690,7 +1690,7 @@ class Meeting(models.Model):
if r['privacy'] == 'private':
for f in r:
recurrent_fields = self._get_recurrent_fields()
public_fields = list(set(recurrent_fields + ['id', 'allday', 'start', 'stop', 'display_start', 'display_stop', 'duration', 'user_id', 'state', 'interval', 'count', 'recurrent_id_date', 'rrule']))
public_fields = list(set(recurrent_fields + ['id', 'active', 'allday', 'start', 'stop', 'display_start', 'display_stop', 'duration', 'user_id', 'state', 'interval', 'count', 'recurrent_id_date', 'rrule']))
if f not in public_fields:
if isinstance(r[f], list):
r[f] = []