|
<ej-grid id="Grid" [dataSource]="data" [allowPaging]="true" >
<e-columns>
<e-column field="OrderID" headerText="OrderID" [isPrimaryKey]="true" width="75"></e-column>
<e-column field="CustomerID" headerText="CustomerID" width="80"></e-column>
<e-column field="EmployeeID" headerText="EmployeeID" width="80"></e-column>
<e-column field="Freight" headerText="Freight" width="90" ></e-column>
<e-column field="ShipCountry" headerText="ShipCountry" width="90"></e-column>
</e-columns>
</ej-grid>
|
|
<ej-grid id="Grid" [dataSource]="data" [allowPaging]="true" rowTemplate="#rowTemplate" >
<e-columns>
<e-column headerText="OrderID" width="75"></e-column>
<e-column headerText="CustomerID" width="80"></e-column>
<e-column headerText="EmployeeID" width="80"></e-column>
<e-column headerText="Freight" width="90" ></e-column>
<e-column headerText="ShipCountry" width="90"></e-column>
</e-columns>
<ng-template #rowTemplate e-row-template let-data>
<tr class="e-row">
<td class="e-rowcell">ord:{{data.OrderID}}</td>
<td class="e-rowcell">{{data.CustomerID}}</td>
<td class="e-rowcell">{{data.EmployeeID}}</td>
<td class="e-rowcell">{{data.Freight}}</td>
<td class="e-rowcell">{{data.ShipCountry}}</td>
</tr>
</ng-template>
</ej-grid> |