From 68a847f83da89350340f3b82e3530311d34228e4 Mon Sep 17 00:00:00 2001 From: Daeng Deni Mardaeni Date: Wed, 20 Sep 2023 13:57:25 +0700 Subject: [PATCH] feature: add function _countDocumentOnCardboard --- app/Helpers/Helpers.php | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/app/Helpers/Helpers.php b/app/Helpers/Helpers.php index 30e2c6b..2841c41 100644 --- a/app/Helpers/Helpers.php +++ b/app/Helpers/Helpers.php @@ -1,5 +1,6 @@ find($cardboard_id); + $document_id = $cardboard->cardboard_detail->pluck('document_id')->toArray(); + + return count($document_id); + }