From ec6deb08b3a76f263a2c1ad4a77c0fa18aa7233c Mon Sep 17 00:00:00 2001 From: freesgen Date: Tue, 16 Apr 2019 11:58:06 -0400 Subject: [PATCH] add total rows to pagination results --- src/Rest/CrudExtendedController.php | 1 + 1 file changed, 1 insertion(+) diff --git a/src/Rest/CrudExtendedController.php b/src/Rest/CrudExtendedController.php index 690ba99..4e18a29 100755 --- a/src/Rest/CrudExtendedController.php +++ b/src/Rest/CrudExtendedController.php @@ -99,6 +99,7 @@ public function index($id = null): Response 'limit' => $limit, 'page' => $this->request->getQuery('page', 'int', 1), 'total_pages' => ceil($count / $limit), + 'total_rows' => $count ]; }