domain:
使用一个基本的三元元祖作为基本参数:(field_value, operator, value)
field_value
:使用对象上定义的字段
operator
:操作符, 可以是
- ‘=’ , ‘!=’, ‘>=’, ‘<=’, ‘<’, ‘>’
- ‘like’, ‘ilike’, ‘not like’, ‘not ilike’ (like区分大小写, ilike不区分大小写)
- ‘in’, ‘child_of’(in是双向识别(‘name’, ‘in’, [‘zhang’, ‘li’]) 和([‘zhang’, ‘li’], ‘in’, ‘name’])效果是一样的
value
:用于实际比较的值。
多条件时用 ‘|’ (or), ‘&’ (and), ‘!’ (no) 逻辑运算符链接, 逻辑运算符作为前缀置于条件前面。’|’ , ‘&’ 后接两个条件, ‘!’ 对一个条件取反。无逻辑运算符时默认为’&’。
例如:
- a and b : [ a, b ] 或 [’&’ , a , b ]
- a or b : [’|’, a,b ]
- a and b and c : [a, b, c] 或 [’&’,’&’, a, b, c]
- a or b or c : [’|’,’|’, a , b , c]
- a and b or c : [’|’,’&’, a, b, c]
- a and ( b or c ) : [’&’, a,’|’, b, c]
对选中的多条单据过滤:filtered_domain