From b2d31d0230c8ee7f9b60a5cbba68a16bfbb52c53 Mon Sep 17 00:00:00 2001 From: Yuri Kuznetsov Date: Wed, 17 Jul 2024 00:07:57 +0300 Subject: [PATCH] fix kanban show more --- application/Espo/Tools/Kanban/Api/GetData.php | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/application/Espo/Tools/Kanban/Api/GetData.php b/application/Espo/Tools/Kanban/Api/GetData.php index b91a23ef61..77edc79716 100644 --- a/application/Espo/Tools/Kanban/Api/GetData.php +++ b/application/Espo/Tools/Kanban/Api/GetData.php @@ -56,9 +56,16 @@ class GetData implements ActionAlias $result = $this->service->getData($entityType, $searchParams); + $list = []; + + foreach ($result->getGroups() as $group) { + $list = [...$list, ...$group->collection->getValueMapList()]; + } + return ResponseComposer::json([ 'total' => $result->getTotal(), 'groups' => array_map(fn ($it) => $it->toRaw(), $result->getGroups()), + 'list' => $list, ]); } }