This is a migrated thread and some comments may be shown as answers.

Using Angular templates for rowTemplate

2 Answers 409 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Eric
Top achievements
Rank 1
Eric asked on 17 Jun 2014, 04:05 PM
We're using the kendo.angular integration. Angular cell templates have been working well, here's an example of what we've been doing:

<a href="/\#/accounts/{{account.id}}/users/{{dataItem.id}}/edit">Edit</a>

We're now trying to use an Angular row template, but we can't see how to access the row specific data. {{dataItem.id}} is empty. How can we access the row specific data with an Angular template? 

Here are my environment details:

OS: OS X 10.9.3
Browser: Chrome 35.0.1916.114
jQuery: 2.1.1
KendoUI: 2014.1.528

Any help would be appreciated!

2 Answers, 1 is accepted

Sort by
0
Accepted
Mihai
Telerik team
answered on 18 Jun 2014, 02:12 PM
Hi,

See the last example in this page: http://kendo-labs.github.io/angular-kendo/#/grid-widget

It shows that dataItem works correctly for rowTemplate.  However, as mentioned in the notice after the code, you must include the attribute data-uid="#: uid #" on the row element, otherwise the template will not function properly (this is mentioned in the Kendo docs as well).  Although I didn't see the code, I suspect this is the issue.

Regards,
Mihai
Telerik
 
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
 
0
Eric
Top achievements
Rank 1
answered on 24 Jun 2014, 02:32 PM
Thanks Mihai, that was it!
Tags
Grid
Asked by
Eric
Top achievements
Rank 1
Answers by
Mihai
Telerik team
Eric
Top achievements
Rank 1
Share this question
or