website
gridData: IReport[] = [
{
"date": "9/5/2018",
"reportName": "Report 1",
"reportLink": "http://google.com/",
"reportStatus": "Success"
},
{
"date": "9/7/2018",
"reportName": "Report 2",
"reportLink": "http://yahoo.com/",
"reportStatus": "Success"
},
{
"date": "8/5/2018",
"reportName": "Report 3",
"reportLink": "http://msn.com/",
"reportStatus": "Success"
},]
<kendo-grid [resizable]="true" [data]="gridData" [height]="500">
<kendo-grid-column field="date" title="Date" width="40">
</kendo-grid-column>
<kendo-grid-column field="reportName" title="Report Name" width="50">
</kendo-grid-column>
<kendo-grid-column field="reportLink" title="Report Link" width="50">
<ng-template kendoGridCellTemplate let-dataItem *ngFor="let data of gridData">
<a href="{{data.reportLink}}">{{data.reportLink}}</a>
</ng-template>
</kendo-grid-column>
<kendo-grid-column field="reportStatus" title="Report Status" width="80">
</kendo-grid-column>
</kendo-grid>
我显示我正在gridData中循环的链接,并将其显示为标记。
<kendo-grid-column field="reportLink" title="Report Link" width="50">
<ng-template kendoGridCellTemplate let-dataItem *ngFor="let data of gridData">
<a href="{{data.reportLink}}">{{data.reportLink}}</a>
</ng-template>
</kendo-grid-column>
我的问题是报告链接只显示http:google.com所有的报告。
我做错什么了?我希望看到谷歌网站, 雅虎网站以及msn.com网站作为我的报告链接。
有什么建议吗?谢谢大家!