DataTable lazy loading paginator bug
@tugcekucukoglu could it be this happens at the same time to DataView?
I'm having troubles with both. I tried with :first but just doesn't react to it
Is there any plan when this bug will be fixed? Or is there any workaround?
Hello team, this is happening also in v 2.9.2 and is blocking my team to upgrade from 2.6.0 , do you have plan to look into this? Thanks!
I think I might look into it this week-end and make a PR, but I might just end up replacing :first="lazy ? 0 : d_first" with :first="d_first" (I'm still unclear on why it's always 0 when lazy).
In the meantime, here's my quick hack to get it to work:
{
mounted() {
this.tmpHackFixPaginator();
},
methods: {
tmpHackFixPaginator() {
asSequence(this.$refs.dataTable.$children)
.filter(vm => vm._name === "<DTPaginator>")
.forEach(paginator => {
paginator.d_first = this.first;
});
}
}
}
The DataTable needs to know which row will be the first, just as it needs to know the number of rows.
https://stackblitz.com/edit/lxpxlz-93qeul?file=src%2FApp.vue%3AL106