Closed developman-akl closed 3 years ago
showPagination is definitely unused, I don't remember if we took it out of the templates for some reason. But perPage seems to be working fine for me:
public array $perPageAccepted = [1,2,4];
public int $perPage = 2;
You probably shouldn't override the mount methods.
Added missing showPagination conditional to views: https://github.com/rappasoft/laravel-livewire-tables/commit/c99e8351d4f69fcaa566e7d39734a85bc52c2cfb
Either way, I don't know why you're seeing two types of pagination. Do you have Laravels default pagination views published and modified?
No, I haven't published the default pagination views, also the mount method is not overridden.
Update: Now as I published the livewire paginations, the duplication is gone.
The $perPage issue has something to do with the trait's session if clause. Commenting out the else clause makes it work.
Update:
With the livewire paginations published having these two properties overwritten, the custom $perPage works without modifying the trait:
public int $perPage = 6;
public array $perPageAccepted = [6];
Using 1.5.1 with Tailwind seems like these properties have no effect:
Overwriting
$perPage
in the WithPerPagePagination trait works, should work via overwriting the property too:$showPagination is an unused property. What would be the purpose of it?
With TW it shows duplicated pagination, would be good to be able to switch off each of them, maybe via $showPagination ?
Thank you.