Skip to Content
Меню
Вам необхідно зареєструватися, щоб взаємодіяти зі спільнотою.
Це запитання позначене
1 Відповісти
1162 Переглядів

I need the Domain for the field “source location“ beacuse i need to add it when taking returns from customers 

Аватар
Відмінити
Найкраща відповідь

Hi,


Try the following code.

@api.onchange('customer_id')

 def onchange_customer_id(self):

     if self.customer_id:

         return { 'domain:

          { 'location_id': [('usage', '=' ,'internal'), ('return_location', '=', True)] }

          }


Hope it helps

Аватар
Відмінити