src/Twig/Extension/SonataAdminExtension.php
public function renderListElement(
        Environment $environment,
        $object,
        FieldDescriptionInterface $fieldDescription,
        $params = []
    ) {
        $template = $this->getTemplate(
            $fieldDescription,
            // NEXT_MAJOR: Remove this line and use commented line below instead
            $fieldDescription->getAdmin()->getTemplate('base_list_field'),
            //$this->getTemplateRegistry($fieldDescription->getAdmin()->getCode())->getTemplate('base_list_field'),
            $environment
        );

        return $this->render($fieldDescription, $template, array_merge($params, [
            'admin' => $fieldDescription->getAdmin(),
            'object' => $object,
            'value' => $this->getValueFromFieldDescription($object, $fieldDescription),
            'field_description' => $fieldDescription,
        ]), $environment);
    }
public function renderListElement(
        Environment $environment,
        $object,
        FieldDescriptionInterface $fieldDescription,
        $params = []
    ) {
        $template = $this->getTemplate(
            $fieldDescription,
            // NEXT_MAJOR: Remove this line and use commented line below instead
            $fieldDescription->getAdmin()->getTemplate('base_list_field'),
            //$this->getTemplateRegistry($fieldDescription->getAdmin()->getCode())->getTemplate('base_list_field'),
            $environment
        );

        return $this->render($fieldDescription, $template, array_merge($params, [
            'admin' => $fieldDescription->getAdmin(),
            'object' => $object,
            'value' => $this->getValueFromFieldDescription($object, $fieldDescription),
            'field_description' => $fieldDescription,
        ]), $environment);
    }
public function renderListElement ( Environment $ environment , $ object , FieldDescriptionInterface $ fieldDescription , $ params = [ ] ) { $ template = $ this -> getTemplate ( $ fieldDescription , // NEXT_MAJOR: Remove this line and use commented line below instead $ fieldDescription -> getAdmin ( ) -> getTemplate ( 'base_list_field' ) , //$this->getTemplateRegistry($fieldDescription->getAdmin()->getCode())->getTemplate('base_list_field'), $ environment ) ; return $ this -> render ( $ fieldDescription , $ template , array_merge ( $ params , [ 'admin' => $ fieldDescription -> getAdmin ( ) , 'object' => $ object , 'value' => $ this -> getValueFromFieldDescription ( $ object , $ fieldDescription ) , 'field_description' => $ fieldDescription , ] ) , $ environment ) ; }
render a list element from the FieldDescription.

@param mixed $object
@param array $params

@return string
render a list element from the FieldDescription .