Skip to content
Snippets Groups Projects
Commit 77f2c589 authored by Jinjiu Liu's avatar Jinjiu Liu
Browse files

[FIX] web_editor: deleting copied table causing a false error traceback


Reproduction:
1. Open LibreOffice Calc (linux), create an empty xls file
2. In LibreOffice, input random things as a 4 (rows) by 2 (columns)
table
3. Create a new note in Odoo, copy the table to it
4. Hold Shift and click the place right before the first cell (out of
the table but still in the editable area)
5. Delete the selected table, a trace back popped up

Fix: add an extra condition to make sure parentFragmentTr is not null
before unpacking it

Note: as you probably noticed, the cleared table does not retain the
original dimensions, e.g. it turns to a 2-row, 4-column table. This is a
deeper issue of how we restore the table, and another task will be
created for this. This PR is a first-aid patch to solve the error
message as it confuses the client a lot

opw-3255144

closes odoo/odoo#119674

Signed-off-by: default avatarDavid Monjoie (dmo) <dmo@odoo.com>
parent 13f078e4
No related branches found
No related tags found
No related merge requests found
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