src/Controller/DefaultController.php
private function processPasteTopWithoutReference(
        CollectionInterface $models,
        ModelIdInterface $after = null,
        ModelIdInterface $into = null,
        ModelIdInterface $parent = null
    ) {
        if ($models->count()
            && (($after && (0 === (int) $after->getId()))
                || ($into && (0 === (int) $into->getId())))
        ) {
            $manualSorting  = ViewHelpers::getManualSortingProperty($this->getEnvironment());
            $dataDefinition = $this->getEnvironment()->getDataDefinition();

            if (BasicDefinitionInterface::MODE_HIERARCHICAL === $dataDefinition->getBasicDefinition()->getMode()) {
                $this->relationshipManager->setAllRoot($models);
            }

            $this->pasteTop($models, $manualSorting, $parent);

            $this->triggerPostPasteModel($models);
            $this->clearModelCollection($models);
        }
    }
private function processPasteTopWithoutReference(
        CollectionInterface $models,
        ModelIdInterface $after = null,
        ModelIdInterface $into = null,
        ModelIdInterface $parent = null
    ) {
        if ($models->count()
            && (($after && (0 === (int) $after->getId()))
                || ($into && (0 === (int) $into->getId())))
        ) {
            $manualSorting  = ViewHelpers::getManualSortingProperty($this->getEnvironment());
            $dataDefinition = $this->getEnvironment()->getDataDefinition();

            if (BasicDefinitionInterface::MODE_HIERARCHICAL === $dataDefinition->getBasicDefinition()->getMode()) {
                $this->relationshipManager->setAllRoot($models);
            }

            $this->pasteTop($models, $manualSorting, $parent);

            $this->triggerPostPasteModel($models);
            $this->clearModelCollection($models);
        }
    }
private function processPasteTopWithoutReference ( CollectionInterface $ models , ModelIdInterface $ after = null , ModelIdInterface $ into = null , ModelIdInterface $ parent = null ) { if ( $ models -> count ( ) && ( ( $ after && ( 0 === ( int ) $ after -> getId ( ) ) ) || ( $ into && ( 0 === ( int ) $ into -> getId ( ) ) ) ) ) { $ manualSorting = ViewHelpers :: getManualSortingProperty ( $ this -> getEnvironment ( ) ) ; $ dataDefinition = $ this -> getEnvironment ( ) -> getDataDefinition ( ) ; if ( BasicDefinitionInterface :: MODE_HIERARCHICAL === $ dataDefinition -> getBasicDefinition ( ) -> getMode ( ) ) { $ this -> relationshipManager -> setAllRoot ( $ models ) ; } $ this -> pasteTop ( $ models , $ manualSorting , $ parent ) ; $ this -> triggerPostPasteModel ( $ models ) ; $ this -> clearModelCollection ( $ models ) ; } }
Process paste the content of the clipboard onto the top after a model without reference.

@param CollectionInterface $models The collection of models.
@param ModelIdInterface    $after  The previous model id.
@param ModelIdInterface    $into   The hierarchical parent model id.
@param ModelIdInterface    $parent The parent model id.

@return void
Process paste the content of the clipboard onto the top after a model without reference .