Skip to content
Snippets Groups Projects
Commit 377d3104 authored by DDEV-Local User's avatar DDEV-Local User
Browse files

Added paragraph fields bundle reference update.

parent 863092a6
No related branches found
No related tags found
No related merge requests found
......@@ -450,18 +450,16 @@ class ParagraphsConverter implements ParagraphsConverterInterface {
$paragraphBundleContainerFieldDefinitions = $this->entityFieldManager->getFieldDefinitions('paragraph', self::PARAGRAPH_BUNDLE_CONTAINER_NAME);
$table_mapping = $this->entityTypeManager->getStorage('paragraph')->getTableMapping();
$field_table_names = [];
foreach ($paragraphBundleContainerFieldDefinitions as $field_key) {
foreach ($field_key as $field) {
if ($field->getFieldStorageDefinition()->isBaseField() == FALSE) {
// We do not convert base fields.
$field_name = $field->getName();
$field_table = $table_mapping->getFieldTableName($field_name);
$field_table_names[$field_name] = $field_table;
$field_storage_definition = $field->getFieldStorageDefinition();
$field_revision_table = $table_mapping->getDedicatedRevisionTableName($field_storage_definition);
// Field revision tables DO have the bundle!
$field_table_names[$field_name . '_revision'] = $field_revision_table;
}
foreach ($paragraphBundleContainerFieldDefinitions as $field_key => $field) {
if ($field->getFieldStorageDefinition()->isBaseField() == FALSE) {
// We do not convert base fields.
$field_name = $field->getName();
$field_table = $table_mapping->getFieldTableName($field_name);
$field_table_names[$field_name] = $field_table;
$field_storage_definition = $field->getFieldStorageDefinition();
$field_revision_table = $table_mapping->getDedicatedRevisionTableName($field_storage_definition);
// Field revision tables DO have the bundle!
$field_table_names[$field_name . '_revision'] = $field_revision_table;
}
}
foreach ($field_table_names as $field_table_name) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment