- Home
- Forum
- Angular - EJ 2
- grid
grid
I have try the following code
<ejs-grid #grid [dataSource]='griddata' [height]='300'>
<e-columns>
<e-column>
<ng-template #template let-data>
{{data.user}}-{{data.text}}
</ng-template>
</e-column>
</e-columns>
</ejs-grid>
and it does not work and i have this two error str.replace is not a function and Cannot read property 'getPanel' of undefined. Is there any fix
to this?
SIGN IN To post a reply.
3 Replies
DR
Dhivya Rajendran
Syncfusion Team
April 3, 2018 11:51 AM UTC
Hi Junyi,
Thanks for contacting Syncfusion support,
We have analyzed your query, we are not able to reproduced the reported issue at our end. We have create a sample for your reference, Kindly refer the below code snippet and sample for more information.
Component.html
|
<ejs-grid #grid [dataSource]='data' [height]='300'>
<e-columns>
<e-column>
<ng-template #template let-data>
{{data.EmployeeID}}-{{data.FirstName}}
</ng-template>
</e-column>
</e-columns>
</ejs-grid> |
If we misunderstood your requirement kindly please provide more information about your query or could you please provide sample. It will be more helpful for us to provide a better solution as soon as possible.
Regards,
R.Dhivya
JC
Junyi Cheong
April 5, 2018 05:10 AM UTC
Do you really have to put #template in ng-template and why?? Is there a way to change it because I think it is clashing with my web UI
DR
Dhivya Rajendran
Syncfusion Team
April 6, 2018 09:11 AM UTC
Hi Junyi,
Thanks for you update,
The template reference variable should be same as the property name of the parent directive. Using template reference variable as #template inside the columns directive, will assign the ngTemplate reference to the columns.template property. It is not possible to bind template with different variable name. This is the design of the template handling in Grid.
Regards,
R.Dhivya
SIGN IN To post a reply.
- 3 Replies
- 2 Participants
-
JC Junyi Cheong
- Apr 3, 2018 01:52 AM UTC
- Apr 6, 2018 09:11 AM UTC