我正在使用primeng表..
我有这个onLazyLoad函数
this.apiService.getUsers(this.searchQuery,event.sortField,event.sortOrder===-1? "desc" : "asc",****** PAGE ******).subscribe(
res=>{
if(res){
this.users=res.data.concat(this.users );
}
}然后
p-table [value]="users" (onLazyLoad)="onLazyLoad($event)" [rows]="20" [resetPageOnSort]="true" [resizableColumns]="true" [scrollHeight]="'calc(100vh - 210px)'" [virtualScroll]="true" [virtualRowHeight]="40" [lazy]="true">有没有可能让当前滚动的页面在BE上用于分页?或者我必须更改后端以使用event.first和event.rows
发布于 2021-09-22 20:55:10
@ViewChild("table") table: Table;
this.table.virtualPage这对我来说很有效,但我仍然在寻找类似的解决方案。
https://stackoverflow.com/questions/69290703
复制相似问题