diff options
| author | Achraf (abz) <abz@odoo.com> | 2020-11-26 12:50:52 +0000 |
|---|---|---|
| committer | Nicolas Martinelli <nim@odoo.com> | 2020-11-26 12:57:42 +0000 |
| commit | f6a610d0b1379aa97ad97fb7494a5d269da87775 (patch) | |
| tree | fa3bf96893adcccf3b9179021023e3307039bfdf /addons/hr_holidays | |
| parent | 7b8abac93a588a7a2a653275dd1e2f33c876ff52 (diff) | |
[FIX] calendar, google_calendar, hr_holidays: lost attendees after sync
What are the steps to reproduce your issue ?
1. Install "google_calendar"
2. Log in with "admin"
3. Create an eventX with "admin" and "demo" has attendees
4. Run "Google Calendar Synchronization" from "Scheduled Actions"
What is currently happening ?
eventX is successfully added to Google but without admin
if you sync Odoo to Google one more time, Google will overwrite eventX
and it will remove admin from attendees
What are you expecting to happen ?
Sync Odoo to Google and Google to Odoo without lost attendees
Why is this happening ?
Because there is a filter that prevent addition of current user to the attendees
How to fix the bug ?
Remove the filter
This reverts commit 287ee0f83ae6fd457e5356860c8a8ab5a4e66754.
opw-2382443
closes odoo/odoo#62406
Signed-off-by: Nicolas Martinelli (nim) <nim@odoo.com>
Diffstat (limited to 'addons/hr_holidays')
| -rw-r--r-- | addons/hr_holidays/models/hr_leave.py | 1 | ||||
| -rw-r--r-- | addons/hr_holidays/tests/test_company_leave.py | 2 |
2 files changed, 1 insertions, 2 deletions
diff --git a/addons/hr_holidays/models/hr_leave.py b/addons/hr_holidays/models/hr_leave.py index 0b0da2d6407..9d23004fe8b 100644 --- a/addons/hr_holidays/models/hr_leave.py +++ b/addons/hr_holidays/models/hr_leave.py @@ -895,7 +895,6 @@ class HolidaysRequest(models.Model): 'privacy': 'confidential', 'event_tz': holiday.user_id.tz, 'activity_ids': [(5, 0, 0)], - 'partner_ids': [], } # Add the partner_id (if exist) as an attendee if holiday.user_id and holiday.user_id.partner_id: diff --git a/addons/hr_holidays/tests/test_company_leave.py b/addons/hr_holidays/tests/test_company_leave.py index 00217a267b5..c34c3c93fa2 100644 --- a/addons/hr_holidays/tests/test_company_leave.py +++ b/addons/hr_holidays/tests/test_company_leave.py @@ -313,7 +313,7 @@ class TestCompanyLeave(SavepointCase): }) company_leave._compute_date_from_to() - count = 863 + count = 865 with self.assertQueryCount(__system__=count, admin=count): # Original query count: 1987 # Without tracking/activity context keys: 5154 |
