Hi,
I created a computed Many2Many field. To make it writable, I used the inverted argument to define a reverse function like so:
document_ids = fields.Many2many(..., compute='_compute_document_ids', inverse='_set_document_ids')
def _compute_document_ids(self): ...
def _set_document_ids(self): ...
Then I created a view which makes use of this field with a Kanban or Tree element. So far everything works fine, I can read, create and delete documents.
Now I want to have the Kanban not to be able to create or delete records, only to be able to edit records when opening them. So I tried the following attemps, none of them works:
### 1:
field name="document_ids" mode="kanban" options="{'no_create': True}" />
### 2:
field name="document_ids" mode="kanban" create="0" />
### 3:
field name="document_ids">
tree create="0">
...
No matter if I use Kanban/Tree here, I still have the "add" or "add a line" option. When I make the field readonly, then the add/delete options disappear. But when I open the record details, I also cannot edit the (because read only).
What am I missing? I need to have a computed field for showing related Many2Many records, I do not want to be able to add/remove records from the parent record but be able to edit them in detail view by clicking on them.
THX