Skip to content
Snippets Groups Projects
Commit 21f3f9aa authored by Nasreddin Boulif (bon)'s avatar Nasreddin Boulif (bon)
Browse files

[FIX] google_calendar: sync the right description


Steps to reproduce:

  - Install 'CRM' module (for test purpose)
  - Configure the google calendar credentials on Odoo
  - Go to CRM -> Configuration -> Activity Types and create a new one
  - Set 'Meeting' as Action
  - As default note, add some bullet points:
    ```
    Hello :
      - First point
      - Second point
      - Third point
    ```
  - Open any Opportunity and create a new Activity (in the chatter)
  - Select 'Meeting' as activity type and open the calendar
  - Add a new event (description should be field with the default note)
  - Open the event (on Odoo and/or Google Calendar)

Issue:

  The description of the event is broken (bullet points missing).

Cause:

  When syncing the event from Odoo to Google Calendar, the description
  is converted to plain text (using `html2plaintext` function).
  Then, when syncing the event from Google Calendar to Odoo,
  the description is also updated locally with the remote one.

Solution:

  Don't convert the description to plain text but use
  `tools.html_sanitize` on the html content instead to sanitize it.

opw-3105194

closes odoo/odoo#115304

Signed-off-by: default avatarNasreddin Boulif (bon) <bon@odoo.com>
parent 5464eae5
No related branches found
No related tags found
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment