fix pagination

This commit is contained in:
Kavalar 2024-09-24 15:42:55 +03:00
parent d747203d99
commit 02a3e52b7d

View File

@ -326,7 +326,7 @@ class ListJsonTable extends JasonTable
$hookAfter = $this->afterPrintHook;
$this->html .= $hookAfter($this->data['meta']);
if ($this->pagination) {
if ($this->pagination && $this->data['data']) {
$options = [
'countItem' => $this->data['meta']['total'],
'perPage' => $this->data['meta']['perPage'] ?? 10,