Skip to content

Commit

Permalink
[FIX] web: do not apply default_order if list grouped
Browse files Browse the repository at this point in the history
If the list view is grouped (with a groubpy filter),
the default order must always be the order of the groupby
  • Loading branch information
beledouxdenis committed Feb 9, 2015
1 parent 05e1b3d commit ca70367
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion addons/web/static/src/js/view_list.js
Original file line number Diff line number Diff line change
Expand Up @@ -356,7 +356,7 @@ instance.web.ListView = instance.web.View.extend( /** @lends instance.web.ListVi
//Sort
var default_order = this.fields_view.arch.attrs.default_order,
unsorted = !this.dataset._sort.length;
if (unsorted && default_order) {
if (unsorted && default_order && !this.grouped) {
this.dataset.set_sort(default_order.split(','));
}

Expand Down

0 comments on commit ca70367

Please sign in to comment.