From 02a3e52b7d365c44a32b7580a2246d47ea032736 Mon Sep 17 00:00:00 2001 From: Kavalar Date: Tue, 24 Sep 2024 15:42:55 +0300 Subject: [PATCH] fix pagination --- src/ListJsonTable.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/ListJsonTable.php b/src/ListJsonTable.php index 1907da8..176333e 100644 --- a/src/ListJsonTable.php +++ b/src/ListJsonTable.php @@ -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,