Do not compute twice the children timesheets

review355001
This commit is contained in:
Nicolas Évrard committed 2012-05-15 10:31:09 +02:00
1 parent 65cd211ada
commit 9554f52d3c
1 file changed
+1 -1
+1 -1
View File
@@ -90,7 +90,7 @@ class Work(ModelSQL, ModelView):
('parent', 'child_of', ids),
])
# force inactive ids to be in all_ids
all_ids = all_ids + ids
all_ids = list(set(all_ids + ids))
clause = "SELECT work, sum(hours) FROM timesheet_line "\
"WHERE work IN (%s) "\
% ",".join(('%s',) * len(all_ids))