-
Type: Improvement
-
Status: Resolved
-
Priority: Minor
-
Resolution: Fixed
-
Affects Version/s: 9.10
-
Fix Version/s: 10.3
-
Component/s: Rest API
-
Release Notes Summary:Added `hasContent` enricher for Folderish and Collection
-
Backlog priority:300
-
Sprint:nxGang Sprint 10.3.2, nxGang Sprint 10.3.3
-
Story Points:1
Add an hasContent enricher server side to tell if a `Folderish` or `Collection` container does have content (boolean).
On Web UI, this is yet another tiny thing to load when it comes to fetch a document but at the same time we could leverage it in our table, grid, list elements when it comes to display a Folder/Collection in Web UI: this could spare us useless requests.
–
We must also deprecate children json enricher
ChildrenJsonEnricher.java relies on
wrapper.getSession().getChildren(document.getRef());
which fetches all children -> does not scale.
Better rely on search endpoints with document_content page provider or @children adapter which provides pagination.
+ add a comment in https://doc.nuxeo.com/nxdoc/content-enrichers/