summaryrefslogtreecommitdiff
path: root/addons/website/static/src/js/backend/dashboard.js
diff options
context:
space:
mode:
authorJoren Van Onder <jov@odoo.com>2018-04-26 15:43:43 -0700
committerJeremy Kersten <jke@odoo.com>2018-08-13 19:18:35 +0200
commit5ff87e8039676db5a0c48422998d0cabd556a12d (patch)
tree7a3e7eb76a7bb9f30f36cbc207973e96ccc84227 /addons/website/static/src/js/backend/dashboard.js
parent0e45dfc59101b7dcce842924240373882d6fca8c (diff)
[FIX] website: make filter_duplicate work
itertools' groupby function expects the iterable to be sorted as hinted to in the documentation: "Generally, the iterable needs to already be sorted on the same key function." When running groupby on an unsorted iterable non-adjacent duplicates will remain: >>> from itertools import groupby >>> [e[0] for e in groupby([1, 2, 1])] [1, 2, 1] Because of this filter_duplicate would occassionally return duplicates. To resolve this sort on the key field. Afterwards sort the result on the usual inherit order: (priority, id).
Diffstat (limited to 'addons/website/static/src/js/backend/dashboard.js')
0 files changed, 0 insertions, 0 deletions