forked from 0x2620/pandora
fix queries in smart lists
This commit is contained in:
parent
fea340bc68
commit
a89e654c6d
1 changed files with 5 additions and 5 deletions
|
@ -229,12 +229,12 @@ def parseConditions(conditions, operator, user):
|
||||||
if 'conditions' in condition:
|
if 'conditions' in condition:
|
||||||
q = parseConditions(condition['conditions'],
|
q = parseConditions(condition['conditions'],
|
||||||
condition.get('operator', '&'), user)
|
condition.get('operator', '&'), user)
|
||||||
|
else:
|
||||||
|
q = parseCondition(condition, user)
|
||||||
if isinstance(q, list):
|
if isinstance(q, list):
|
||||||
conn += q
|
conn += q
|
||||||
elif q:
|
elif q:
|
||||||
conn.append(q)
|
conn.append(q)
|
||||||
else:
|
|
||||||
conn.append(parseCondition(condition, user))
|
|
||||||
if conn:
|
if conn:
|
||||||
if operator == '|':
|
if operator == '|':
|
||||||
q = conn[0]
|
q = conn[0]
|
||||||
|
|
Loading…
Reference in a new issue