Open mattamon opened 1 week ago
The method byId of the ElementSearchServiceInterface only returns the IDs of the elements and not the element type.
byId
Since IDs between elements are not unique in Pimcore, this causes problems if the IDs eg. of an asset, object or document are the same.
https://github.com/pimcore/generic-data-index-bundle/blob/1.x/src/Service/Search/SearchService/Element/ElementSearchService.php#L79-L81
I noticed this while implementing the dependencies for Studio Backend.
For the mentioned byId it should be fine because you get a search result model which indicates the element type.
But for the ElementSearchResult::getIds() you are right, this doesn't make sense without the type.
ElementSearchResult::getIds()
The method
byId
of the ElementSearchServiceInterface only returns the IDs of the elements and not the element type.Since IDs between elements are not unique in Pimcore, this causes problems if the IDs eg. of an asset, object or document are the same.
https://github.com/pimcore/generic-data-index-bundle/blob/1.x/src/Service/Search/SearchService/Element/ElementSearchService.php#L79-L81
I noticed this while implementing the dependencies for Studio Backend.