hydrateSearchResult example

if (!empty($term)) {
                $this->addSearchTermCondition($entity$builder$term);
            }

            $builder->setFirstResult($offset)
                ->setMaxResults($limit);
        }

        $pagination = $this->getPaginator($builder);
        $data = iterator_to_array($pagination);

        $data = $this->hydrateSearchResult($entity$data);

        $this->View()->assign([
            'success' => true,
            'data' => $data,
            'total' => $pagination->count(),
        ]);
    }

    /** * Sanitizes the passed term and queries the different areas of the search */
    
Home | Imprint | This part of the site doesn't use cookies.