Skip to Content
Menu
You need to be registered to interact with the community.
This question has been flagged
1 Odgovori
4712 Prikazi

Hi, i want to change the domain filter of a existing field. e.g. in class stock_move in file: addons/stock/stock.py

'product_id': fields.many2one('product.product', 'Product', required=True, select=True, domain=[('state','<>','obsolete')],states={'done': [('readonly', True)]}), 

I want to write a new module for that, which overwrites the existing column with the new domain. How can I do this?

Avatar
Opusti
Avtor Best Answer

Inheriting the existing model and overwriting the existing _column in my mymodule.py seems to work. No view.xml needed.

Avatar
Opusti
Related Posts Odgovori Prikazi Aktivnost
1
mar. 15
3691
1
jul. 24
1837
1
maj 24
2677
1
jan. 24
4940
2
mar. 23
2689