Trevor de Koekkoek
Trevor de Koekkoek

Reputation: 2506

How do you create a drop-down editor in the Angular 2 Kendo grid

Using the Angular 2 Kendo Grid, I currently can specify an editor for text, numeric, and boolean. How do I create a custom editor or more specifically a drop-down list editor?

Upvotes: 1

Views: 6236

Answers (1)

Vincent V.
Vincent V.

Reputation: 776

You can define templates in grid columns, where you can put whatever you want, including dropdowns:

<kendo-grid-column field="ProductName" title="Product Name">
    <ng-template kendoGridEditTemplate let-dataItem="dataItem">
        <kendo-dropdownlist [(ngModel)]="dataItem.itemId" [data]="listItems"></kendo-dropdownlist>
    </ng-template>
</kendo-grid-column>

http://www.telerik.com/kendo-angular-ui/components/grid/editing/editing-template-forms/

Upvotes: 7

Related Questions