跳至內容
選單
此問題已被標幟
4 回覆
10310 瀏覽次數

Hello Guys:

Please, i have a problem with context defined in xml view.

Need Help please and thanks a lot in advance :)

Here is my code:

    <field name="domain">[('mail_validated','=',False),'|',(('mail_removed','=',False),('mail_duree','&lt;=',15))]</field>

And Here is what i get :

AssertionError: This domain is syntactically not correct: [[u'mail_validated', u'=', False], u'|', [[u'mail_removed', u'=', False], [u'mail_duree', u'<=', 15]]]

頭像
捨棄

<field name="domain">['|', '|', ('mail_validated','=',False),(('mail_removed','=',False),('mail_duree','&lt;=',15))]</field>

作者

it doesnt work :/ the same error

AssertionError: This domain is syntactically not correct: [u'|', u'|', [u'mail_validated', u'=', False], [[u'mail_removed', u'=', False], [u'mail_duree', u'<=', 15]]]

作者 最佳答案

Hi everybody!!!

Here is the solution to my problem:

Instead of using domain i have used filter_domain.

<field name="filter_domain">['|', ('mail_validated','=',False),(('mail_removed','=',False),('period_mail','&lt;=',15))]</field>

Best Regards.

頭像
捨棄
最佳答案

Try this <field name="domain">[('mail_validated','=',False),'|',('mail_removed','=',False),('mail_duree','&lt;=',15)]</field>

頭像
捨棄
相關帖文 回覆 瀏覽次數 活動
2
11月 23
7520
2
2月 21
3605
7
2月 19
13758
6
12月 17
8917
5
10月 22
13843