devextreme-angular
devextreme-angular copied to clipboard
DxDataGrid CellTemplate
How can i use DxTemplate to customize cellTemplate in dxDataGrid?
Before:
<div data-options="dxTemplate:{ name:'buttonDeleteCellTemplate' }">
<div dx-button="{bindingOptions: {onClick: 'vm.buttonClicked'}, 'text': 'Delete'}"></div>
</div>
in Column: { dataField: 'whatever', dataType: 'string', caption: 'superCaption' cellTemplate: 'buttonDeleteCellTemplate' }
Now?
Hi,
Thank you for pointing out this case. It appears to be a bug. We suppose it should work as follows:
<div *dxTemplate="let cellData = data of 'buttonDeleteCellTemplate'">
<div dx-button (onClick)="buttonClicked()" text="Delete"></div>
</div>
Hi, so am I getting this right, are cellTemplates currently not working with devextreme-angular2 in dx-data-grid?
Hi staran,
You are right. We'll fix this issue and publish an update soon.