src/Contao/View/Contao2BackendView/BaseView.php
public function handleAjaxCall()
    {
        $environment = $this->getEnvironment();
        $input       = $environment->getInputProvider();

        if (true === ($input->hasParameter('id'))) {
            // Redefine the parameter id if this isn´t model id conform.
            if (false === \strpos($input->getParameter('id'), '::')) {
                $modelId = new ModelId($input->getParameter('table'), $input->getParameter('id'));
                $input->setParameter('id', $modelId->getSerialized());
            }
            $modelId      = ModelId::fromSerialized($input->getParameter('id'));
            $dataProvider = $environment->getDataProvider($modelId->getDataProviderName());
            $model        = $dataProvider->fetch($dataProvider->getEmptyConfig()->setId($modelId->getId()));
        }

        $this->addAjaxPropertyForEditAll();

        $handler = new Ajax3X();
        $handler->executePostActions(new DcCompat($environment, ($model ?? null)));
    }
public function handleAjaxCall()
    {
        $environment = $this->getEnvironment();
        $input       = $environment->getInputProvider();

        if (true === ($input->hasParameter('id'))) {
            // Redefine the parameter id if this isn´t model id conform.
            if (false === \strpos($input->getParameter('id'), '::')) {
                $modelId = new ModelId($input->getParameter('table'), $input->getParameter('id'));
                $input->setParameter('id', $modelId->getSerialized());
            }
            $modelId      = ModelId::fromSerialized($input->getParameter('id'));
            $dataProvider = $environment->getDataProvider($modelId->getDataProviderName());
            $model        = $dataProvider->fetch($dataProvider->getEmptyConfig()->setId($modelId->getId()));
        }

        $this->addAjaxPropertyForEditAll();

        $handler = new Ajax3X();
        $handler->executePostActions(new DcCompat($environment, ($model ?? null)));
    }
public function handleAjaxCall ( ) { $ environment = $ this -> getEnvironment ( ) ; $ input = $ environment -> getInputProvider ( ) ; if ( true === ( $ input -> hasParameter ( 'id' ) ) ) { // Redefine the parameter id if this isn´t model id conform. if ( false === \ strpos ( $ input -> getParameter ( 'id' ) , '::' ) ) { $ modelId = new ModelId ( $ input -> getParameter ( 'table' ) , $ input -> getParameter ( 'id' ) ) ; $ input -> setParameter ( 'id' , $ modelId -> getSerialized ( ) ) ; } $ modelId = ModelId :: fromSerialized ( $ input -> getParameter ( 'id' ) ) ; $ dataProvider = $ environment -> getDataProvider ( $ modelId -> getDataProviderName ( ) ) ; $ model = $ dataProvider -> fetch ( $ dataProvider -> getEmptyConfig ( ) -> setId ( $ modelId -> getId ( ) ) ) ; } $ this -> addAjaxPropertyForEditAll ( ) ; $ handler = new Ajax3X ( ) ; $ handler -> executePostActions ( new DcCompat ( $ environment , ( $ model ?? null ) ) ) ; }
Handle an ajax call by passing it to the relevant handler class.

The handler class might(!) exit the script.

@return void
Handle an ajax call by passing it to the relevant handler class .