Skip to content

Commit b1c4b15

Browse files
committed
[FIX] spreadsheet_oca: The tables overlap when added to an existing spreadsheet
Before these changes, when a table was added to an existing spreadsheet, it was always being added to row 0 of the sheet, since the call to getCell always returned undefined. After making these changes, the call is made correctly and the cell’s content is retrieved. Since the isEmpty function no longer exists, we now check directly whether it contains the content key.
1 parent e7b0703 commit b1c4b15

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

spreadsheet_oca/static/src/spreadsheet/bundle/spreadsheet_action.esm.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -147,9 +147,9 @@ export class ActionSpreadsheetOca extends Component {
147147
while (row >= 0) {
148148
for (var col = maxcols; col >= 0; col--) {
149149
if (
150-
spreadsheet_model.getters.getCell(sheetId, col, row) !==
151-
undefined &&
152-
!spreadsheet_model.getters.getCell(sheetId, col, row).isEmpty()
150+
spreadsheet_model.getters.getCell({ sheetId, col, row }) !==
151+
+ undefined &&
152+
spreadsheet_model.getters.getCell({ sheetId, col, row }).content
153153
) {
154154
filled = true;
155155
break;

0 commit comments

Comments
 (0)