Skip to Content
เมนู
คุณต้องลงทะเบียนเพื่อโต้ตอบกับคอมมูนิตี้
คำถามนี้ถูกตั้งค่าสถานะ
2 ตอบกลับ
6583 มุมมอง

model is ir.actions.act_window

I want to have context evaluate as OR not AND for following

<field name="context">{'search_default_writer': active_id }</field> <field name="context">{'search_default_director':active_id }</field> <field name="context">{'search_default_producer':active_id }</field>

Obviously these need to be in a single context statement, but what is correct format.

อวตาร
ละทิ้ง
คำตอบที่ดีที่สุด

Just separate with , <field name="context">{'search_default_writer': active_id, 'search_default_director': active_id, 'search_default_producer': active_id }</field>

อวตาร
ละทิ้ง
ผู้เขียน

I tried that initially - creates an AND logic statement (ie values = A and values = B and values = C) not an OR statement. I tried putting the '|' at the front but it didn't like that

คำตอบที่ดีที่สุด

I think that you are making some mistakes here.

The context sent on the ir.actions is going to be a value in the context dictionary. It's not conditional, it's only going to send all the context. Domains are conditional, but context are only variables that you are sending to the window.

อวตาร
ละทิ้ง
Related Posts ตอบกลับ มุมมอง กิจกรรม
1
ม.ค. 25
1399
0
ก.ค. 22
2462
3
ก.ย. 20
3118
Significance of context ? แก้ไขแล้ว
2
ธ.ค. 15
4723
0
มี.ค. 15
3447