angular-2-data-table icon indicating copy to clipboard operation
angular-2-data-table copied to clipboard

[limit]="5" is not working when it first load.

Open San13 opened this issue 6 years ago • 3 comments

I use limit by default 5. But it keeping showing me all records at first load. However, if i manually key in limit value, it works. Please suggest.

San13 avatar Mar 04 '18 09:03 San13

Having exactly the same issue. Did you solved it?

okpablo avatar Mar 14 '18 15:03 okpablo

same here, any update in this issue ?

esraagalal avatar Mar 20 '18 13:03 esraagalal

Change your limit inside initializeTable as well.

public initializeTable(inspections: Inspection[]) { this.tableResource = new DataTableResource(inspections); this.tableResource.query({ index: 0, offset: 0, limit: 20, sortBy: 'inspectedDate', sortAsc: true }) .then(items => this.items = items); this.tableResource.count() .then(count => this.itemCount = count); }

San13 avatar Jul 16 '18 07:07 San13