Zum Inhalt springen
Menü
Sie müssen registriert sein, um mit der Community zu interagieren.
Diese Frage wurde gekennzeichnet
1 Antworten
4924 Ansichten

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
Verwerfen
Autor Beste Antwort

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

Avatar
Verwerfen
Verknüpfte Beiträge Antworten Ansichten Aktivität
1
März 15
3961
1
Juli 24
2182
1
Mai 24
2913
1
Jan. 24
5542
2
März 23
3004