started migration process
- installed and enabled dependencies - created materio_migrate module - drafted thesaurus, tags, showroom, company, materiau migrations - exported config files
This commit is contained in:
@@ -0,0 +1,35 @@
|
||||
id: d7_taxonomy_vocabulary_company
|
||||
label: Taxonomy vocabularies Company
|
||||
migration_group: d7_materio
|
||||
migration_tags:
|
||||
- Drupal 7
|
||||
- Configuration
|
||||
- Materio
|
||||
|
||||
source:
|
||||
plugin: d7_taxonomy_vocabulary
|
||||
bundle: company
|
||||
|
||||
destination:
|
||||
plugin: entity:taxonomy_vocabulary
|
||||
|
||||
process:
|
||||
vid:
|
||||
-
|
||||
plugin: make_unique_entity_field
|
||||
source: machine_name
|
||||
entity_type: taxonomy_vocabulary
|
||||
field: vid
|
||||
length: 32
|
||||
migrated: true
|
||||
-
|
||||
# This plugin checks if the vocabulary being migrated is the one used by
|
||||
# Forum. If so, we use the machine name that Forum expects. Otherwise, we
|
||||
# leave it unchanged.
|
||||
plugin: forum_vocabulary
|
||||
machine_name: forums
|
||||
label: name
|
||||
name: name
|
||||
description: description
|
||||
hierarchy: hierarchy
|
||||
weight: weight
|
@@ -0,0 +1,35 @@
|
||||
id: d7_taxonomy_vocabulary_showroom
|
||||
label: Taxonomy vocabularies Showroom
|
||||
migration_group: d7_materio
|
||||
migration_tags:
|
||||
- Drupal 7
|
||||
- Configuration
|
||||
- Materio
|
||||
|
||||
source:
|
||||
plugin: d7_taxonomy_vocabulary
|
||||
bundle: showroom
|
||||
|
||||
destination:
|
||||
plugin: entity:taxonomy_vocabulary
|
||||
|
||||
process:
|
||||
vid:
|
||||
-
|
||||
plugin: make_unique_entity_field
|
||||
source: machine_name
|
||||
entity_type: taxonomy_vocabulary
|
||||
field: vid
|
||||
length: 32
|
||||
migrated: true
|
||||
-
|
||||
# This plugin checks if the vocabulary being migrated is the one used by
|
||||
# Forum. If so, we use the machine name that Forum expects. Otherwise, we
|
||||
# leave it unchanged.
|
||||
plugin: forum_vocabulary
|
||||
machine_name: forums
|
||||
label: name
|
||||
name: name
|
||||
description: description
|
||||
hierarchy: hierarchy
|
||||
weight: weight
|
@@ -0,0 +1,35 @@
|
||||
id: d7_taxonomy_vocabulary_tags
|
||||
label: Taxonomy vocabularies Tags
|
||||
migration_group: d7_materio
|
||||
migration_tags:
|
||||
- Drupal 7
|
||||
- Configuration
|
||||
- Materio
|
||||
|
||||
source:
|
||||
plugin: d7_taxonomy_vocabulary
|
||||
bundle: tag_libres
|
||||
|
||||
destination:
|
||||
plugin: entity:taxonomy_vocabulary
|
||||
|
||||
process:
|
||||
vid:
|
||||
-
|
||||
plugin: make_unique_entity_field
|
||||
source: machine_name
|
||||
entity_type: taxonomy_vocabulary
|
||||
field: vid
|
||||
length: 32
|
||||
migrated: true
|
||||
-
|
||||
# This plugin checks if the vocabulary being migrated is the one used by
|
||||
# Forum. If so, we use the machine name that Forum expects. Otherwise, we
|
||||
# leave it unchanged.
|
||||
plugin: forum_vocabulary
|
||||
machine_name: forums
|
||||
label: name
|
||||
name: name
|
||||
description: description
|
||||
hierarchy: hierarchy
|
||||
weight: weight
|
@@ -0,0 +1,35 @@
|
||||
id: d7_taxonomy_vocabulary_thesaurus
|
||||
label: Taxonomy vocabularies Thesaurus
|
||||
migration_group: d7_materio
|
||||
migration_tags:
|
||||
- Drupal 7
|
||||
- Configuration
|
||||
- Materio
|
||||
|
||||
source:
|
||||
plugin: d7_taxonomy_vocabulary
|
||||
bundle: onthologie
|
||||
|
||||
destination:
|
||||
plugin: entity:taxonomy_vocabulary
|
||||
|
||||
process:
|
||||
vid:
|
||||
-
|
||||
plugin: make_unique_entity_field
|
||||
source: machine_name
|
||||
entity_type: taxonomy_vocabulary
|
||||
field: vid
|
||||
length: 32
|
||||
migrated: true
|
||||
-
|
||||
# This plugin checks if the vocabulary being migrated is the one used by
|
||||
# Forum. If so, we use the machine name that Forum expects. Otherwise, we
|
||||
# leave it unchanged.
|
||||
plugin: forum_vocabulary
|
||||
machine_name: forums
|
||||
label: name
|
||||
name: name
|
||||
description: description
|
||||
hierarchy: hierarchy
|
||||
weight: weight
|
@@ -0,0 +1,40 @@
|
||||
id: d7_node_entity_translation_materiau
|
||||
label: Materiau
|
||||
migration_group: d7_materio
|
||||
migration_tags:
|
||||
- Drupal 7
|
||||
- translation
|
||||
- Content
|
||||
- Multilingual
|
||||
- Materio
|
||||
deriver: Drupal\node\Plugin\migrate\D7NodeDeriver
|
||||
|
||||
source:
|
||||
plugin: d7_node_entity_translation
|
||||
bundle: materiau
|
||||
|
||||
destination:
|
||||
plugin: entity:node
|
||||
translations: true
|
||||
destination_module: content_translation
|
||||
bundle: materiau
|
||||
|
||||
migration_dependencies:
|
||||
required:
|
||||
- d7_node_materiau
|
||||
|
||||
process:
|
||||
nid: entity_id
|
||||
type: type
|
||||
langcode: language
|
||||
title: title
|
||||
uid: uid
|
||||
status: status
|
||||
created: created
|
||||
changed: changed
|
||||
promote: promote
|
||||
sticky: sticky
|
||||
revision_uid: revision_uid
|
||||
revision_log: log
|
||||
revision_timestamp: timestamp
|
||||
content_translation_source: source
|
@@ -0,0 +1,45 @@
|
||||
id: d7_node_materiau
|
||||
label: Nodes Materiau
|
||||
migration_group: d7_materio
|
||||
audit: true
|
||||
migration_tags:
|
||||
- Drupal 7
|
||||
- Content
|
||||
deriver: Drupal\node\Plugin\migrate\D7NodeDeriver
|
||||
|
||||
source:
|
||||
plugin: d7_node
|
||||
bundle: materiau
|
||||
|
||||
destination:
|
||||
plugin: entity:node
|
||||
bundle: materiau
|
||||
|
||||
migration_dependencies:
|
||||
required:
|
||||
- d7_taxonomy_term_thesaurus
|
||||
- d7_taxonomy_term_tags
|
||||
- d7_taxonomy_term_showroom
|
||||
- d7_taxonomy_term_company
|
||||
process:
|
||||
# If you are using this file to build a custom migration consider removing
|
||||
# the nid and vid fields to allow incremental migrations.
|
||||
# In D7, nodes always have a tnid, but it's zero for untranslated nodes.
|
||||
# We normalize it to equal the nid in that case.
|
||||
# @see \Drupal\node\Plugin\migrate\source\d7\Node::prepareRow().
|
||||
nid: tnid
|
||||
vid: vid
|
||||
langcode:
|
||||
plugin: default_value
|
||||
source: language
|
||||
default_value: "und"
|
||||
title: title
|
||||
uid: node_uid
|
||||
status: status
|
||||
created: created
|
||||
changed: changed
|
||||
promote: promote
|
||||
sticky: sticky
|
||||
revision_uid: revision_uid
|
||||
revision_log: log
|
||||
revision_timestamp: timestamp
|
@@ -0,0 +1,51 @@
|
||||
id: d7_taxonomy_term_company
|
||||
label: Taxonomy terms Company
|
||||
migration_group: d7_materio
|
||||
audit: true
|
||||
migration_tags:
|
||||
- Drupal 7
|
||||
- Content
|
||||
- Materio
|
||||
deriver: Drupal\taxonomy\Plugin\migrate\D7TaxonomyTermDeriver
|
||||
|
||||
source:
|
||||
plugin: d7_taxonomy_term
|
||||
bundle: company
|
||||
|
||||
destination:
|
||||
plugin: entity:taxonomy_term
|
||||
bundle: company
|
||||
|
||||
# migration_dependencies:
|
||||
# required:
|
||||
# - d7_taxonomy_vocabulary_company
|
||||
# optional:
|
||||
# - d7_field_instance
|
||||
|
||||
process:
|
||||
# If you are using this file to build a custom migration consider removing
|
||||
# the tid field to allow incremental migrations.
|
||||
tid: tid
|
||||
vid:
|
||||
plugin: migration_lookup
|
||||
migration: d7_taxonomy_vocabulary_company
|
||||
source: vid
|
||||
name: name
|
||||
'description/value': description
|
||||
'description/format': format
|
||||
weight: weight
|
||||
# Only attempt to stub real (non-zero) parents.
|
||||
parent_id:
|
||||
-
|
||||
plugin: skip_on_empty
|
||||
method: process
|
||||
source: parent
|
||||
-
|
||||
plugin: migration_lookup
|
||||
migration: d7_taxonomy_term_company
|
||||
parent:
|
||||
plugin: default_value
|
||||
default_value: 0
|
||||
source: '@parent_id'
|
||||
forum_container: is_container
|
||||
changed: timestamp
|
@@ -0,0 +1,51 @@
|
||||
id: d7_taxonomy_term_showroom
|
||||
label: Taxonomy terms Showroom
|
||||
migration_group: d7_materio
|
||||
audit: true
|
||||
migration_tags:
|
||||
- Drupal 7
|
||||
- Content
|
||||
- Materio
|
||||
deriver: Drupal\taxonomy\Plugin\migrate\D7TaxonomyTermDeriver
|
||||
|
||||
source:
|
||||
plugin: d7_taxonomy_term
|
||||
bundle: showroom
|
||||
|
||||
destination:
|
||||
plugin: entity:taxonomy_term
|
||||
bundle: showroom
|
||||
|
||||
# migration_dependencies:
|
||||
# required:
|
||||
# - d7_taxonomy_vocabulary_showroom
|
||||
# optional:
|
||||
# - d7_field_instance
|
||||
|
||||
process:
|
||||
# If you are using this file to build a custom migration consider removing
|
||||
# the tid field to allow incremental migrations.
|
||||
tid: tid
|
||||
vid:
|
||||
plugin: migration_lookup
|
||||
migration: d7_taxonomy_vocabulary_showroom
|
||||
source: vid
|
||||
name: name
|
||||
'description/value': description
|
||||
'description/format': format
|
||||
weight: weight
|
||||
# Only attempt to stub real (non-zero) parents.
|
||||
parent_id:
|
||||
-
|
||||
plugin: skip_on_empty
|
||||
method: process
|
||||
source: parent
|
||||
-
|
||||
plugin: migration_lookup
|
||||
migration: d7_taxonomy_term_showroom
|
||||
parent:
|
||||
plugin: default_value
|
||||
default_value: 0
|
||||
source: '@parent_id'
|
||||
forum_container: is_container
|
||||
changed: timestamp
|
@@ -0,0 +1,51 @@
|
||||
id: d7_taxonomy_term_tags
|
||||
label: Taxonomy terms Tags
|
||||
migration_group: d7_materio
|
||||
audit: true
|
||||
migration_tags:
|
||||
- Drupal 7
|
||||
- Content
|
||||
- Materio
|
||||
deriver: Drupal\taxonomy\Plugin\migrate\D7TaxonomyTermDeriver
|
||||
|
||||
source:
|
||||
plugin: d7_taxonomy_term
|
||||
bundle: tag_libres
|
||||
|
||||
destination:
|
||||
plugin: entity:taxonomy_term
|
||||
bundle: tags
|
||||
|
||||
# migration_dependencies:
|
||||
# required:
|
||||
# - d7_taxonomy_vocabulary_tags
|
||||
# optional:
|
||||
# - d7_field_instance
|
||||
|
||||
process:
|
||||
# If you are using this file to build a custom migration consider removing
|
||||
# the tid field to allow incremental migrations.
|
||||
# tid: tid
|
||||
vid:
|
||||
plugin: migration_lookup
|
||||
migration: d7_taxonomy_vocabulary_tags
|
||||
source: vid
|
||||
name: name
|
||||
'description/value': description
|
||||
'description/format': format
|
||||
weight: weight
|
||||
# Only attempt to stub real (non-zero) parents.
|
||||
parent_id:
|
||||
-
|
||||
plugin: skip_on_empty
|
||||
method: process
|
||||
source: parent
|
||||
-
|
||||
plugin: migration_lookup
|
||||
migration: d7_taxonomy_term_tags
|
||||
parent:
|
||||
plugin: default_value
|
||||
default_value: 0
|
||||
source: '@parent_id'
|
||||
forum_container: is_container
|
||||
changed: timestamp
|
@@ -0,0 +1,51 @@
|
||||
id: d7_taxonomy_term_thesaurus
|
||||
label: Taxonomy terms Thesaurus
|
||||
migration_group: d7_materio
|
||||
audit: true
|
||||
migration_tags:
|
||||
- Drupal 7
|
||||
- Content
|
||||
- Materio
|
||||
deriver: Drupal\taxonomy\Plugin\migrate\D7TaxonomyTermDeriver
|
||||
|
||||
source:
|
||||
plugin: d7_taxonomy_term
|
||||
bundle: onthologie
|
||||
|
||||
destination:
|
||||
plugin: entity:taxonomy_term
|
||||
bundle: thesaurus
|
||||
|
||||
# migration_dependencies:
|
||||
# required:
|
||||
# - d7_taxonomy_vocabulary_thesaurus
|
||||
# optional:
|
||||
# - d7_field_instance
|
||||
|
||||
process:
|
||||
# If you are using this file to build a custom migration consider removing
|
||||
# the tid field to allow incremental migrations.
|
||||
tid: tid
|
||||
vid:
|
||||
plugin: migration_lookup
|
||||
migration: d7_taxonomy_vocabulary_thesaurus
|
||||
source: vid
|
||||
name: name
|
||||
'description/value': description
|
||||
'description/format': format
|
||||
weight: weight
|
||||
# Only attempt to stub real (non-zero) parents.
|
||||
parent_id:
|
||||
-
|
||||
plugin: skip_on_empty
|
||||
method: process
|
||||
source: parent
|
||||
-
|
||||
plugin: migration_lookup
|
||||
migration: d7_taxonomy_term_thesaurus
|
||||
parent:
|
||||
plugin: default_value
|
||||
default_value: 0
|
||||
source: '@parent_id'
|
||||
forum_container: is_container
|
||||
changed: timestamp
|
@@ -0,0 +1,11 @@
|
||||
id: d7_materio
|
||||
label: D7 Materio
|
||||
description: Drupal 7 materio content migration to Drupal 8.
|
||||
source_type: Drupal 7
|
||||
shared_configuration:
|
||||
source:
|
||||
key: legacy
|
||||
dependencies:
|
||||
enforced:
|
||||
module:
|
||||
- materio_migrate
|
26
modules/custom/materio_migrate/materio_migrate.info.yml
Normal file
26
modules/custom/materio_migrate/materio_migrate.info.yml
Normal file
@@ -0,0 +1,26 @@
|
||||
name: Materio Migration
|
||||
type: module
|
||||
description: Defines custom migration for materio (from d7 to d8).
|
||||
core: 8.x
|
||||
package: Materio
|
||||
dependencies:
|
||||
- drupal:migrate
|
||||
- drupal:migrate_drupal
|
||||
- drupal:migrate_drupal_multilingual
|
||||
# - drupal:field_group_migrate
|
||||
- migrate_plus:migrate_plus
|
||||
- migrate_tools:migrate_tools
|
||||
- config_devel
|
||||
|
||||
config_devel:
|
||||
install:
|
||||
- migrate_plus.migration_group.d7_materio
|
||||
# - migrate_plus.migration.d7_taxonomy_vocabulary_tags
|
||||
- migrate_plus.migration.d7_taxonomy_term_tags
|
||||
# - migrate_plus.migration.d7_taxonomy_vocabulary_thesaurus
|
||||
- migrate_plus.migration.d7_taxonomy_term_thesaurus
|
||||
# - migrate_plus.migration.d7_taxonomy_vocabulary_showroom
|
||||
- migrate_plus.migration.d7_taxonomy_term_showroom
|
||||
# - migrate_plus.migration.d7_taxonomy_vocabulary_company
|
||||
- migrate_plus.migration.d7_taxonomy_term_company
|
||||
- migrate_plus.migration.d7_node_entity_translation_materiau
|
29
modules/custom/materio_migrate/readme.md
Normal file
29
modules/custom/materio_migrate/readme.md
Normal file
@@ -0,0 +1,29 @@
|
||||
https://www.drupaleasy.com/blogs/ultimike/2016/04/drupal-6-drupal-81x-custom-content-migration
|
||||
|
||||
https://thinkshout.com/blog/2017/05/skipping-a-version-migrating-from-drupal-6-to-drupal-8-with-drupal-migrate/
|
||||
|
||||
https://www.drupal.org/docs/8/upgrade/known-issues-when-upgrading-from-drupal-6-or-7-to-drupal-8
|
||||
|
||||
https://drupal.stackexchange.com/questions/164612/how-do-i-remove-a-configuration-object-from-the-active-configuration
|
||||
|
||||
https://www.metaltoad.com/blog/drupal-8-migrations-part-3-migrating-taxonomies-drupal-7
|
||||
|
||||
https://www.sitepoint.com/your-first-drupal-8-migration/
|
||||
|
||||
https://evolvingweb.ca/blog/drupal-8-migration-migrating-taxonomy-term-references-part-2
|
||||
|
||||
[text to taxonomy term](http://boylesoftware.com/blog/drupal-8-migration-taxonomy-term-lookups/)
|
||||
|
||||
[Upgrading Drupal 6 and i18n Content Translation to Drupal 8](https://www.dunix-data.de/blog/upgrading_drupal_6_and_i18n_content_translation_to_drupal_8)
|
||||
|
||||
[Migrating Drupal 7 File Entities to Drupal 8 Media Entities](https://www.previousnext.com.au/blog/migrating-drupal-7-file-entities-drupal-8-media-entities)
|
||||
|
||||
[D6 Taxonomy Term Reference Field is not migrated to D8 Field](https://www.drupal.org/node/2884240)
|
||||
|
||||
[Migrer un site Drupal 6 ou Drupal 7 vers Drupal 8](https://www.drupalfacile.org/sites/drupalfacile/files/blog/2016/06/dcnantes2016-migrerd6d7versd8.pdf)
|
||||
|
||||
[Migrating Aliases and Redirects to Drupal 8](https://evolvingweb.ca/blog/migrating-aliases-and-redirects-drupal-8)
|
||||
|
||||
[Migrating Drupal 7 redirects to Drupal 8](http://activelamp.com/blog/drupal/migrating-drupal-8-redirects/)
|
||||
|
||||
[How to refresh new migrations in Drupal 8 migration module?](https://drupal.stackexchange.com/questions/191435/how-to-refresh-new-migrations-in-drupal-8-migration-module)
|
Reference in New Issue
Block a user