تخطي للذهاب إلى المحتوى
القائمة
لقد تم الإبلاغ عن هذا السؤال
1 الرد
3350 أدوات العرض

Hello all ,


Is it possible to do record rule like this : 


['|',('company_id','=',False),('company_id','=',[product.company_id.id])]


As i keep getting an error :

Can i say in a record rule i want the company id to equal the product.product company_id ?


الصورة الرمزية
إهمال
أفضل إجابة

Hii,

Check By putting this.

['|',('company_id','=',False),('company_id','child_of',[product.company_id.id])]

الصورة الرمزية
إهمال
الكاتب

could explain the reason behind product instead product.product ?

product.product is a model and product is variable that will have to store product and product.product have company id in this model.

المنشورات ذات الصلة الردود أدوات العرض النشاط
1
نوفمبر 24
1586
1
أغسطس 15
7271
3
يناير 24
16178
1
مارس 15
5553
0
مارس 15
8923