Reputation: 1
I have implemented ag-grid in angular 6 and enabled server side rendering the sever hits the endpoint ,where the data is been stored but there is no response given to the frontend and there is no error log too
<div style=" box-sizing: border-box;" class="ag_customtable">
<ag-grid-angular #agGrid style="width: 100%; height: 100%;" id="myGrid" [rowData]="rowData" class="ag-theme-balham" [columnDefs]="columnDefs" [enableSorting]="true" [enableFilter]="true" [suppressRowClickSelection]="true" [debug]="true" [rowSelection]="rowSelection" [enableColResize]="true" [enableRangeSelection]="true" [paginationAutoPageSize]="true" [pagination]="true" [defaultColDef]="defaultColDef" (gridReady)="onGridReady($event)" (cellClicked)="openModalDialog1($event)">
</ag-grid-angular>
onGridReady(params)
{
this.gridApi = params.api;
this.gridColumnApi = params.columnApi;
this.xorusapiService.assettable_data().subscribe(data =>
{
this.rowData = data;
});
}
Im my server im getting
ag-Grid.Context: >> creating ag-Application Context
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.Context: bean [object O created
ag-Grid.GridCore: ready
ag-Grid.Context: >> ag-Application Context ready - component is alive
ag-Grid.BalancedColumnTreeBuilder: Number of levels for grouped columns is 0
ag-Grid -> initialised successfully, enterprise = false
inside _ assetable data
/export
/export
ag-Grid.SelectionController: reset
ag-Grid.SelectionController: reset
/export is the endpoint im hitting
Could someone help me to resolve this issue?
Upvotes: 0
Views: 1724
Reputation: 11
I faced this issue and it was because of the style. Actually the data was loading, but the grid was not displaying in the UI. I changed the style to style="width: 100%; height: 700px;" to resolve this.
<ag-grid-angular #agGrid style="width: 100%; height: 700px" id="myGrid" [rowData]="rowData" class="ag-theme-balham" [columnDefs]="columnDefs" [enableSorting]="true" [enableFilter]="true" [suppressRowClickSelection]="true" [debug]="true" [rowSelection]="rowSelection" [enableColResize]="true" [enableRangeSelection]="true" [paginationAutoPageSize]="true" [pagination]="true" [defaultColDef]="defaultColDef" (gridReady)="onGridReady($event)" (cellClicked)="openModalDialog1($event)">
</ag-grid-angular>
Upvotes: 1