Commit 1f5bba78 authored by Jérome Perrin's avatar Jérome Perrin

fix group by for node budget variations when using category membership on movement.


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@40983 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent f4497523
...@@ -196,9 +196,12 @@ class NodeBudgetVariation(BudgetVariation): ...@@ -196,9 +196,12 @@ class NodeBudgetVariation(BudgetVariation):
if axis == 'movement': if axis == 'movement':
axis = 'default_%s_uid' % base_category axis = 'default_%s_uid' % base_category
query_dict['select_list'] = [axis] query_dict['select_list'] = [axis]
if axis == 'movement_strict_membership': query_dict['group_by'] = [axis]
elif axis == 'movement_strict_membership':
axis = 'default_strict_%s_uid' % base_category axis = 'default_strict_%s_uid' % base_category
query_dict['select_list'] = [axis] query_dict['select_list'] = [axis]
query_dict['group_by'] = [axis]
else:
query_dict['group_by_%s' % axis] = True query_dict['group_by_%s' % axis] = True
# TODO: This is not correct if axis is a category (such as # TODO: This is not correct if axis is a category (such as
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment