Document/Subscriber/PageSubscriber.php
public function handleHydrate(HydrateEvent $event)
    {
        $document = $event->getDocument();
        $node = $event->getNode();
        $propertyName = $this->propertyEncoder->systemName(static::FIELD);
        if (!$document instanceof PageBehavior || !$node->hasProperty($propertyName)) {
            return;
        }

        $node = $event->getNode();
        $document->setPageNumber($node->getPropertyValue($this->propertyEncoder->systemName(static::FIELD)));
    }
public function handleHydrate(HydrateEvent $event)
    {
        $document = $event->getDocument();
        $node = $event->getNode();
        $propertyName = $this->propertyEncoder->systemName(static::FIELD);
        if (!$document instanceof PageBehavior || !$node->hasProperty($propertyName)) {
            return;
        }

        $node = $event->getNode();
        $document->setPageNumber($node->getPropertyValue($this->propertyEncoder->systemName(static::FIELD)));
    }
public function handleHydrate ( HydrateEvent $ event ) { $ document = $ event -> getDocument ( ) ; $ node = $ event -> getNode ( ) ; $ propertyName = $ this -> propertyEncoder -> systemName ( static :: FIELD ) ; if ( ! $ document instanceof PageBehavior || ! $ node -> hasProperty ( $ propertyName ) ) { return ; } $ node = $ event -> getNode ( ) ; $ document -> setPageNumber ( $ node -> getPropertyValue ( $ this -> propertyEncoder -> systemName ( static :: FIELD ) ) ) ; }
Set the page-number to existing pages.

@param HydrateEvent $event
Set the page - number to existing pages .