Below is the grid that I have developed using Kendo-Angular2. I need a click event on the row and in the event I need the row information. I wrote a general click event and tried o get the row information, but it doesn't work if I go to second page in the pagination. Is there a simple row click event that gives the row information.
plnkr: http://plnkr.co/edit/h0fVaP4NykRiILA7dyHn?p=preview
click event code:
ngAfterViewInit() {
this.renderer.listen(this.gridRef.nativeElement, "mousedown", (event) => {
if (!event.target.matches('tbody>tr *')) {
return;
}
const gridData = this.grid.data;
const tr = event.target.closest('tr');
const dataItem = gridData.data[tr.rowIndex + this.grid.skip];
console.log(dataItem);
});
}
http://www.telerik.com/kendo-angular-ui/components/grid/selection/- mast3rd3mon