From bca51764f593b3b9acd9bbd03e3b4e63da810fbb Mon Sep 17 00:00:00 2001 From: Victor Champonnois Date: Thu, 3 Aug 2023 14:38:42 +0200 Subject: [PATCH] [ADD] improve comment and propose removal --- eater/models/partner.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/eater/models/partner.py b/eater/models/partner.py index dd13c2574..43ed9a4ca 100644 --- a/eater/models/partner.py +++ b/eater/models/partner.py @@ -37,8 +37,10 @@ def write(self, values): ) % partner.parent_eater_id.name ) - # replace many2many command when writing on child_eater_ids to just - # remove the link + # fixme : is this still necessary ? In a many2many widget, removing an item + # is a "3" (unlink) command. In which case would this be a delete command ? + # replace many2many command when writing on child_eater_ids to unlink + # rather than delete if "child_eater_ids" in values: for command in values["child_eater_ids"]: if command[0] == 2: