Sorting not working when template let-column="column" used
See original GitHub issueI’m submitting a … (check one with “x”)
[x] bug report => search github for a similar issue or PR before submitting
[ ] feature request
[ ] support request => Please do not submit support request here
Current behavior
When <template let-column="column"> tag is added to an expressive template, sorting function for that column doesn’t work.
Expected behavior
Sorting should work.
Reproduction of the problem
In your own example in the documentation you can see this behaviour https://plnkr.co/edit/iH1e7cIAdX5Ds4jY7WYc?p=preview
<template let-column="column"> Hi + {{column.name}} </template>What is the motivation / use case for changing the behavior?
Sort by column with a customized title
Please tell us about your environment:
Window 10
-
Table version: 0.7.x
0.11.2
-
Angular version: 2.0.x
2.1.1
-
Browser: [all | Chrome XX | Firefox XX | IE XX | Safari XX | Mobile Chrome XX | Android X.X Web Browser | iOS XX Safari | iOS XX UIWebView | iOS XX WKWebView ]
all
-
Language: [all | TypeScript X.X | ES6/7 | ES5] TS 2.0.3
Issue Analytics
- State:
- Created 7 years ago
- Reactions:4
- Comments:15 (4 by maintainers)
Top GitHub Comments
The above works for let-value, but for let-column It doesn’t. Even with prop and name. This resolved it though
https://github.com/swimlane/ngx-datatable/issues/681#issuecomment-297386597
Thanks ! Using
prop
andname
worked for me<datatable-column name="Foo Bar" prop="fooBar"> <template let-value="value"> {{value}} </template> </datatable-column>