src/Configuration/PropertyConfigPass.php
private function processMetadataConfig(array $backendConfig)
    {
        foreach ($backendConfig['entities'] as $entityName => $entityConfig) {
            $properties = [];
            foreach ($entityConfig['properties'] as $propertyName => $propertyMetadata) {
                $typeGuess = $this->getFormTypeGuessOfProperty($entityConfig['class'], $propertyName);
                $requiredGuess = $this->getFormRequiredGuessOfProperty($entityConfig['class'], $propertyName);

                $guessedType = null !== $typeGuess
                    ? FormTypeHelper::getTypeName($typeGuess->getType())
                    : $propertyMetadata['type'];

                $guessedTypeOptions = null !== $typeGuess
                    ? $typeGuess->getOptions()
                    : [];

                if (null !== $requiredGuess) {
                    $guessedTypeOptions['required'] = $requiredGuess->getValue();
                }

                $properties[$propertyName] = \array_replace(
                    $this->defaultEntityFieldConfig,
                    $propertyMetadata,
                    [
                        'property' => $propertyName,
                        'dataType' => $propertyMetadata['type'],
                        'fieldType' => $guessedType,
                        'type_options' => $guessedTypeOptions,
                    ]
                );

                // 'boolean' properties are displayed by default as toggleable
                // flip switches (if the 'edit' action is enabled for the entity)
                if ('boolean' === $properties[$propertyName]['dataType'] && !\in_array('edit', $entityConfig['disabled_actions'])) {
                    $properties[$propertyName]['dataType'] = 'toggle';
                }
            }

            $backendConfig['entities'][$entityName]['properties'] = $properties;
        }

        return $backendConfig;
    }
private function processMetadataConfig(array $backendConfig)
    {
        foreach ($backendConfig['entities'] as $entityName => $entityConfig) {
            $properties = [];
            foreach ($entityConfig['properties'] as $propertyName => $propertyMetadata) {
                $typeGuess = $this->getFormTypeGuessOfProperty($entityConfig['class'], $propertyName);
                $requiredGuess = $this->getFormRequiredGuessOfProperty($entityConfig['class'], $propertyName);

                $guessedType = null !== $typeGuess
                    ? FormTypeHelper::getTypeName($typeGuess->getType())
                    : $propertyMetadata['type'];

                $guessedTypeOptions = null !== $typeGuess
                    ? $typeGuess->getOptions()
                    : [];

                if (null !== $requiredGuess) {
                    $guessedTypeOptions['required'] = $requiredGuess->getValue();
                }

                $properties[$propertyName] = \array_replace(
                    $this->defaultEntityFieldConfig,
                    $propertyMetadata,
                    [
                        'property' => $propertyName,
                        'dataType' => $propertyMetadata['type'],
                        'fieldType' => $guessedType,
                        'type_options' => $guessedTypeOptions,
                    ]
                );

                // 'boolean' properties are displayed by default as toggleable
                // flip switches (if the 'edit' action is enabled for the entity)
                if ('boolean' === $properties[$propertyName]['dataType'] && !\in_array('edit', $entityConfig['disabled_actions'])) {
                    $properties[$propertyName]['dataType'] = 'toggle';
                }
            }

            $backendConfig['entities'][$entityName]['properties'] = $properties;
        }

        return $backendConfig;
    }
$entityConfig['properties'] stores the raw metadata provided by Doctrine.
This method adds some other options needed for EasyAdmin backends. This is
required because $entityConfig['properties'] will be used as the fields of
the views that don't define their fields.

@param array $backendConfig

@return array