- ->findAllTags($this->getUser()->getId());
-
- $flatTags = [];
-
- foreach ($tags as $tag) {
- $nbEntries = $repository->countAllEntriesByUserIdAndTagId(
- $this->getUser()->getId(),
- $tag->getId()
- );
-
- $flatTags[] = [
- 'id' => $tag->getId(),
- 'label' => $tag->getLabel(),
- 'slug' => $tag->getSlug(),
- 'nbEntries' => $nbEntries,
- ];
- }