Technical mailing list archives

Re: Set field attributes in views dynamically from python

Adrian Enns
- 10/27/2016 11:26:10



Warning and Domain

To change domain or send a warning just return the usual dictionary. Be careful not to use @api.onein that case as it will mangle the dictionary (put it in a list, which is not supported by the web client).

Christian-Lassen-Str. 9
53117 Bonn
Tel.:   0228 / 28 699 500
Mob.: 0176 / 62 31 08 25

Das Unternehmen GUARD-TEC ist eine Marke / Unternehmenszweig der "WEBER-TECH GROUP" und wird vertreten durch den Geschäftsinhaber Waldemar Weber. Gerichtsstand Bonn.

Privacy & Confidentiality Notice

The information contained in this e-mail is intended for the named recipients only. It may contain privileged and confidential information and if you are not the adressee or the person responsible for delivering this to the adressee, you may not copy, distribute or take action in reliance on it. If you have received this e-mail in error, please notify us immediately by returning the original message to the sender by e-mail.       

2016-10-27 12:17 GMT+02:00 Bohdan Lisnenko <>:
Maybe set condition in domain?

2016-10-27 12:52 GMT+03:00 Cristian Esposito <>:


i need to set a domain on a standard field many2one, based on change of a custom value.

def onchange_flag_riordino_products(self):
if self.flag_riordino_products: # if this flag == True: need to set domain
# set domain
# if the flag == False: no domain
Does someone have any idea?

Thanks a lot for your support


Post to:

Post to: