diff --git a/src/DataDefinitionsBundle/Fetcher/ObjectsFetcher.php b/src/DataDefinitionsBundle/Fetcher/ObjectsFetcher.php index 6dfb67a8..0c9bf78b 100644 --- a/src/DataDefinitionsBundle/Fetcher/ObjectsFetcher.php +++ b/src/DataDefinitionsBundle/Fetcher/ObjectsFetcher.php @@ -17,8 +17,8 @@ namespace Wvision\Bundle\DataDefinitionsBundle\Fetcher; use InvalidArgumentException; +use Pimcore\Model\DataObject\AbstractObject; use Pimcore\Model\DataObject\ClassDefinition; -use Pimcore\Model\DataObject\Concrete; use Pimcore\Model\DataObject\Listing; use Wvision\Bundle\DataDefinitionsBundle\Context\FetcherContextInterface; use Wvision\Bundle\DataDefinitionsBundle\Model\ExportDefinitionInterface; @@ -60,12 +60,12 @@ private function getClassListing(ExportDefinitionInterface $definition, array $p $rootNode = null; $conditionFilters = []; if (isset($params['root'])) { - $rootNode = Concrete::getById($params['root']); + $rootNode = AbstractObject::getById($params['root']); if (null !== $rootNode) { $quotedPath = $list->quote($rootNode->getRealFullPath()); $quotedWildcardPath = $list->quote(str_replace('//', '/', $rootNode->getRealFullPath().'/').'%'); - $conditionFilters[] = '(o_path = '.$quotedPath.' OR o_path LIKE '.$quotedWildcardPath.')'; + $conditionFilters[] = '(path = '.$quotedPath.' OR path LIKE '.$quotedWildcardPath.')'; } } @@ -79,10 +79,10 @@ private function getClassListing(ExportDefinitionInterface $definition, array $p } if (isset($params['only_direct_children']) && $params['only_direct_children'] == 'true' && null !== $rootNode) { - $conditionFilters[] = 'o_parentId = '.$rootNode->getId(); + $conditionFilters[] = 'parentId = '.$rootNode->getId(); } - if (isset($params['condition'])) { + if (isset($params['condition'])) { $conditionFilters[] = '('.$params['condition'].')'; } if (isset($params['ids'])) {