diff options
| author | Denis Ledoux <dle@odoo.com> | 2016-04-19 16:45:19 +0200 |
|---|---|---|
| committer | Denis Ledoux <dle@odoo.com> | 2016-04-19 16:56:20 +0200 |
| commit | e1a17b433d87d871e1e215b7dfd182faa274eb5f (patch) | |
| tree | cd18e8cdf927e2d0c8912ce17bf55adce31c3e9c /addons/web/static/lib/jquery.mjs.nestedSortable/jquery.mjs.nestedSortable.js | |
| parent | 09a9e4aeb57b92b03ba73f831d8943ec24cb9589 (diff) | |
[FIX] audittrail: prevent loop between models having *2m between each other
When setting rules on models having o2m/m2m relationship
between each other
e.g.
- `res.partner`:
o2m `sale_order_ids` to `sale.order`
- `sale.order`
o2m `message_follower_ids` to `res.partner`
an infinite loop could occur if records
of these models referenced records of the
other models in their o2m relationships
e.g.
- `res.partner` ID 68:
`sale.order` ID 9 in its `sale_order_ids`
- `sale.order` ID 9:
`res.partner` ID 68 in its `message_partner_ids`
This revision solves this use case, by passing the already
treated records in the context and checking that the records
haven't yet be treated before making the recursive call.
This revision makes sure to not break the API of methods
`get_data_context` and `prepare_audittrail_log_line`
(a new parameter had to be introduced for the above purpose)
opw-670904
Diffstat (limited to 'addons/web/static/lib/jquery.mjs.nestedSortable/jquery.mjs.nestedSortable.js')
0 files changed, 0 insertions, 0 deletions
