0

When I have array in json data, that holds 21 rows with 3 diffrent types of "AssetTypeName" (column) which is the column that the grid is groupped by, it will result in a grid that shows the same group multiple times. The only group that appears one time is a group that has only one row in that particular AssetTypeName category.

For example AssetTypeName = "Domestic bonds" should have 5 rows but the grid shows the groups three times which all contains the same 2 first rows in that category.

When I expand some group-row, all the duplicated groups will expand.

here is a example that replicates this issue:

[http://plnkr.co/edit/fBqNq33XmQTYS4Ga9wrW?p=preview][1]

Sincerly - aghaux

aghaux
  • 729
  • 4
  • 14
  • 38
  • editor would not let me set a link to plunkr example without decorate it with code??, sorry about that... this looks messy :) – aghaux May 28 '16 at 16:19
  • That's because you're supposed to post your code in the question. Demo's, such as your plunkr, are optional and non-essential. If the plunkr link dies, so does the usefulness of your question as a reference, *unless the code is part of the question*. http://stackoverflow.com/help/how-to-ask – Michael Benjamin May 28 '16 at 16:57
  • Thank you for that explanation, with that plunkr link I am providing a runnable version of this issue which is in my mind a better way than paste 150 lines of code on this page. – aghaux May 29 '16 at 00:02

3 Answers3

0

this happened to me when using sorting and grouping together. when I removed the sorting for all columns this was working just fine. Guess it's a bug in ui-grid.

Roy Horev
  • 106
  • 7
0

The fix for me was to turn off useExternalSorting - looks like grouping and this option are incompatible.

https://github.com/angular-ui/ui-grid/issues/5270?_pjax=%23js-repo-pjax-container

0

while using grouping and sorting together , set sort priority

 sort: { priority: 1, direction: 'asc' }

and group priority must be same as sort priority .