Document/Subscriber/ArticleSubscriber.php
public function hydratePageData(HydrateEvent $event)
    {
        $document = $event->getDocument();
        if (!$document instanceof ArticleDocument) {
            return;
        }

        $pages = $event->getNode()->getPropertyValueWithDefault(
            $this->propertyEncoder->localizedSystemName(self::PAGES_PROPERTY, $document->getOriginalLocale()),
            json_encode([])
        );
        $pages = json_decode($pages, true);

        if (LocalizationState::SHADOW === $this->documentInspector->getLocalizationState($document)) {
            $pages = $this->loadPageDataForShadow($event->getNode(), $document, $pages);
        }

        $document->setPages($pages);
    }
public function hydratePageData(HydrateEvent $event)
    {
        $document = $event->getDocument();
        if (!$document instanceof ArticleDocument) {
            return;
        }

        $pages = $event->getNode()->getPropertyValueWithDefault(
            $this->propertyEncoder->localizedSystemName(self::PAGES_PROPERTY, $document->getOriginalLocale()),
            json_encode([])
        );
        $pages = json_decode($pages, true);

        if (LocalizationState::SHADOW === $this->documentInspector->getLocalizationState($document)) {
            $pages = $this->loadPageDataForShadow($event->getNode(), $document, $pages);
        }

        $document->setPages($pages);
    }
public function hydratePageData ( HydrateEvent $ event ) { $ document = $ event -> getDocument ( ) ; if ( ! $ document instanceof ArticleDocument ) { return ; } $ pages = $ event -> getNode ( ) -> getPropertyValueWithDefault ( $ this -> propertyEncoder -> localizedSystemName ( self :: PAGES_PROPERTY , $ document -> getOriginalLocale ( ) ) , json_encode ( [ ] ) ) ; $ pages = json_decode ( $ pages , true ) ; if ( LocalizationState :: SHADOW === $ this -> documentInspector -> getLocalizationState ( $ document ) ) { $ pages = $ this -> loadPageDataForShadow ( $ event -> getNode ( ) , $ document , $ pages ) ; } $ document -> setPages ( $ pages ) ; }
Hydrate page-data.

@param HydrateEvent $event
Hydrate page - data .