diff --git a/eZ/Bundle/EzPublishCoreBundle/Resources/config/papi.yml b/eZ/Bundle/EzPublishCoreBundle/Resources/config/papi.yml index b55326e714..6dc24ac8f7 100644 --- a/eZ/Bundle/EzPublishCoreBundle/Resources/config/papi.yml +++ b/eZ/Bundle/EzPublishCoreBundle/Resources/config/papi.yml @@ -52,7 +52,7 @@ services: alias: ezpublish.spi.search_engine.indexer ezpublish.spi.search_engine: - class: eZ\Publish\SPI\Search\Handler + class: eZ\Publish\SPI\Search\VersatileHandler factory: ["@ezpublish.api.search_engine.factory", buildSearchEngine] public: false lazy: true diff --git a/eZ/Publish/Core/Search/Legacy/Content/Handler.php b/eZ/Publish/Core/Search/Legacy/Content/Handler.php index cd391e1986..f4e3b403b2 100644 --- a/eZ/Publish/Core/Search/Legacy/Content/Handler.php +++ b/eZ/Publish/Core/Search/Legacy/Content/Handler.php @@ -8,7 +8,7 @@ use eZ\Publish\SPI\Persistence\Content; use eZ\Publish\SPI\Persistence\Content\Location; -use eZ\Publish\SPI\Search\Handler as SearchHandlerInterface; +use eZ\Publish\SPI\Search\VersatileHandler as SearchHandlerInterface; use eZ\Publish\Core\Persistence\Legacy\Content\Mapper as ContentMapper; use eZ\Publish\Core\Persistence\Legacy\Content\Location\Mapper as LocationMapper; use eZ\Publish\Core\Search\Legacy\Content\Location\Gateway as LocationGateway; @@ -367,6 +367,11 @@ public function deleteContent($contentId, $versionId = null) $this->indexerGateway->remove($contentId, $versionId); } + public function deleteTranslation(int $contentId, string $languageCode): void + { + // Not needed with Legacy Storage/Search Engine + } + /** * Deletes a location from the index. * @@ -395,4 +400,9 @@ public function commit($flush = false) { // Not needed with Legacy Storage/Search Engine } + + public function supports(int $capabilityFlag): bool + { + return false; + } } diff --git a/eZ/Publish/SPI/Search/VersatileHandler.php b/eZ/Publish/SPI/Search/VersatileHandler.php new file mode 100644 index 0000000000..f00970f5c1 --- /dev/null +++ b/eZ/Publish/SPI/Search/VersatileHandler.php @@ -0,0 +1,19 @@ +