kendo-labs/angular-kendo

Reload event on Angular-Kendo grid

Opened this issue · 1 comments

I have a grid with Angular and Kendo like as example page.
It's possible to reload the grid by clicking an external button ?
And apply some filter by taking the value of an external text box?

Is there an example of how to do that?

Thank you very much.

To refresh the grid, you need to get a reference to its element and call some methods on it. It's pretty ugly, but if you keep this logic in a service you can keep the ugly in one spot.

var gridEl = angular.element('#myGridElement');
gridEl.data('kendoGrid').dataSource.read();
gridEl.data('kendoGrid').refresh();

To take external values as parameters, you need to use a custom transport.read/create/update method. Inside this method, you merge your external values with Kendo's.
http://docs.telerik.com/kendo-ui/api/framework/datasource#configuration-transport