Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Grouping fails when 'field' in columnDef is referred to some javascript object than a primitive type. #4493

Closed
akshitSinghal1989 opened this issue Oct 8, 2015 · 2 comments

Comments

@akshitSinghal1989
Copy link

Grouping fails when 'field' in columnDef is referred to some javascript object than a primitive type, having own custom sorting Algorithm and a cellFilter defined to show exact value from 'field' object.

Code At Plunker:
http://plnkr.co/edit/ddpNlVneR7Wro2VeelD1?p=preview

Steps:-

  1. Group Address Column
  2. Expand All
  3. Check Grouping didn't worked as expected (It duplicates last item data for each group)
@akshitSinghal1989
Copy link
Author

When I debugged the code, I found that there is an issue on how ui-grid creates GroupingHeaderCache Map. It directly uses the value referred by 'field' as a key to create map of header rows for grouped column. Which is always [object Object] in this case.

@akshitSinghal1989 akshitSinghal1989 changed the title Grouping fails when 'field' in columnDef is referred to some javascript object than a primitive type. Grouping fails when 'field' in columnDef is referred to some javascript object than a primitive type. label:grid-grouping Oct 8, 2015
@akshitSinghal1989 akshitSinghal1989 changed the title Grouping fails when 'field' in columnDef is referred to some javascript object than a primitive type. label:grid-grouping Grouping fails when 'field' in columnDef is referred to some javascript object than a primitive type. Oct 8, 2015
akshitSinghal1989 pushed a commit to akshitSinghal1989/ui-grid that referenced this issue Oct 8, 2015
…pt object than a primitive type.

Grouping fails when 'field' in columnDef is referred to some javascript object
than a primitive type. Resolves issue
[4493](angular-ui#4493)
@ankit5990
Copy link

+1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants