I have a grid:
<kendo-grid #grid="kendoGrid" [data]="userView | async" [pageSize]="20" [sort]="state.sort" [filter]="state.filter" [pageable]="true" [sortable]="{ allowUnsort: true, mode: 'multiple' }" [filterable]="true" [resizable]="true" (dataStateChange)="dataStateChange($event)"> </kendo-grid>
userView function returns 21 records,the first page shows 20 records its all good but the issue is when I go to the second page of the grid, it shows one record but the page number below shows 1 and I can't go back the page 1 in the grid which I had the 20 records, here are my functions:
public state: State = { skip: 0, take: 500 } public userView: Observable<GridDataResult>; constructor( private userListService: UserListService){ this.userView = userListService; userListService.query(this.state, this.querySharedUsers); } public dataStateChange(state: DataStateChangeEvent): void { this.state = state; this.userListService.query(state, this.querySharedUsers); }
I tried to change the state.take to 20 but the function returned 20 records which it should return 21 and the grid had only one page, is anyone familiar with this kind of configuring kendo ui paging?