src/Contao/View/Contao2BackendView/PanelBuilder.php
public function build()
    {
        $panel = new DefaultPanelContainer();
        $panel->setEnvironment($this->environment);

        /** @var Contao2BackendViewDefinitionInterface $viewDefinition */
        $viewDefinition = $this
            ->environment
            ->getDataDefinition()
            ->getDefinition(Contao2BackendViewDefinitionInterface::NAME);

        foreach ($viewDefinition->getPanelLayout()->getRows() as $panelKey => $row) {
            $panelRow = new DefaultPanel();
            $panel->addPanel($panelKey, $panelRow);
            foreach ($row as $element) {
                /** @var ElementInformationInterface $element */
                if (null !== $instance = $this->createElement($element)) {
                    $panelRow->addElement($element->getName(), $instance);
                }
            }
        }

        return $panel;
    }
public function build()
    {
        $panel = new DefaultPanelContainer();
        $panel->setEnvironment($this->environment);

        /** @var Contao2BackendViewDefinitionInterface $viewDefinition */
        $viewDefinition = $this
            ->environment
            ->getDataDefinition()
            ->getDefinition(Contao2BackendViewDefinitionInterface::NAME);

        foreach ($viewDefinition->getPanelLayout()->getRows() as $panelKey => $row) {
            $panelRow = new DefaultPanel();
            $panel->addPanel($panelKey, $panelRow);
            foreach ($row as $element) {
                /** @var ElementInformationInterface $element */
                if (null !== $instance = $this->createElement($element)) {
                    $panelRow->addElement($element->getName(), $instance);
                }
            }
        }

        return $panel;
    }
public function build ( ) { $ panel = new DefaultPanelContainer ( ) ; $ panel -> setEnvironment ( $ this -> environment ) ; /** @var Contao2BackendViewDefinitionInterface $viewDefinition */ $ viewDefinition = $ this -> environment -> getDataDefinition ( ) -> getDefinition ( Contao2BackendViewDefinitionInterface :: NAME ) ; foreach ( $ viewDefinition -> getPanelLayout ( ) -> getRows ( ) as $ panelKey => $ row ) { $ panelRow = new DefaultPanel ( ) ; $ panel -> addPanel ( $ panelKey , $ panelRow ) ; foreach ( $ row as $ element ) { /** @var ElementInformationInterface $element */ if ( null !== $ instance = $ this -> createElement ( $ element ) ) { $ panelRow -> addElement ( $ element -> getName ( ) , $ instance ) ; } } } return $ panel ; }
Build the panel.

@return DefaultPanelContainer
Build the panel .