export class AppComponent {
@ViewChild("grid")
public grid: GridComponent;
public parentData: Object[];
public childGrid: any;
public filterSettings: Object;
ngOnInit(): void {
this.toolbar = ["ExcelExport", "PdfExport", "CsvExport"];
this.filterSettings = { type: "Menu" };
this.parentData = employeeData;
this.childGrid = {
dataSource: orderDatas,
queryString: "EmployeeID",
allowPaging: true,
pageSettings: { pageSize: 6, pageCount: 5 },
columns: [
. . . . . . . .
{ field: "ShipRegion", headerText: "Ship Region", width: 150 } //null value field
]
};
}
}
|
this.childGrid = {
dataSource: JSON.parse(JSON.stringify(cusdatas)),
queryString: "invoiceId",
allowPaging: true,
pageSettings: { pageSize: 6, pageCount: 5 },
columns: [
{ field: 'billNo', headerText: 'Bill No', textAlign: 'Left', width: 120 },
{ field: 'ratePerCase', headerText: 'Rate/Case', textAlign: 'Right', width: 120, format: 'n2' },
{ field: 'qtyInCases', headerText: 'Qty Cases', textAlign: 'Left', width: 120 },
{ field: 'qtyLooseBottle', headerText: 'Qty Bottle', textAlign: 'Left', width: 120 },
{ field: 'qtyBulkLiters', headerText: 'Qty BL', textAlign: 'Left', width: 120, format: 'n2' },
{ field: 'batchNo', headerText: 'Batch No', textAlign: 'Left', width: 120, format: 'string' }
]
};
|