Commit 85c5a6c
committed
[FIX] util/pg: fix rename_model with m2m fields
In the case of renamed model being referenced in a many2many table (for having
or being referenced in a m2m field), related `ir_model_fields.column1` (and 2)
aren't updated. However, the m2m tables column names themselves are properly
updated. This lead to an error because the `column1` is referring to a column
whose name is already overwritten, and to a crash because the returned foreign
keys list is empty but accessed at [0].
[tbg](https://upgrade.odoo.com/odoo/tbg/2156)
closes #319
Signed-off-by: Christophe Simonis (chs) <chs@odoo.com>1 parent 87c3e7e commit 85c5a6c
1 file changed
+22
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1465 | 1465 | | |
1466 | 1466 | | |
1467 | 1467 | | |
| 1468 | + | |
| 1469 | + | |
| 1470 | + | |
| 1471 | + | |
| 1472 | + | |
| 1473 | + | |
| 1474 | + | |
| 1475 | + | |
| 1476 | + | |
| 1477 | + | |
| 1478 | + | |
| 1479 | + | |
| 1480 | + | |
| 1481 | + | |
| 1482 | + | |
| 1483 | + | |
| 1484 | + | |
| 1485 | + | |
| 1486 | + | |
| 1487 | + | |
| 1488 | + | |
| 1489 | + | |
1468 | 1490 | | |
1469 | 1491 | | |
1470 | 1492 | | |
| |||
0 commit comments