mirror of
https://github.com/farmOS/farmOS.git
synced 2024-02-23 11:37:38 +01:00
Migrate farmOS roles.
This commit is contained in:
parent
3e6dd3089a
commit
74effb652c
|
@ -0,0 +1,39 @@
|
|||
langcode: en
|
||||
status: true
|
||||
dependencies:
|
||||
enforced:
|
||||
module:
|
||||
- farm_migrate
|
||||
id: farm_migrate_role
|
||||
label: 'Roles'
|
||||
migration_group: farm_migrate
|
||||
migration_tags:
|
||||
- 'Drupal 7'
|
||||
- 'farmOS 1.x'
|
||||
class: Drupal\migrate\Plugin\Migration
|
||||
field_plugin_method: null
|
||||
cck_plugin_method: null
|
||||
source:
|
||||
plugin: d7_user_role
|
||||
destination:
|
||||
plugin: 'entity:user_role'
|
||||
process:
|
||||
id:
|
||||
-
|
||||
plugin: static_map
|
||||
source: name
|
||||
map:
|
||||
Farm Manager: farm_manager
|
||||
Farm Worker: farm_worker
|
||||
Farm Viewer: farm_viewer
|
||||
-
|
||||
plugin: entity_lookup
|
||||
value_key: id
|
||||
entity_type: user_role
|
||||
ignore_case: true
|
||||
-
|
||||
plugin: skip_on_empty
|
||||
method: row
|
||||
migration_dependencies:
|
||||
required: { }
|
||||
optional: { }
|
|
@ -60,7 +60,13 @@ process:
|
|||
init:
|
||||
plugin: get
|
||||
source: init
|
||||
roles:
|
||||
plugin: migration_lookup
|
||||
migration: farm_migrate_role
|
||||
source: roles
|
||||
no_stub: true
|
||||
migration_dependencies:
|
||||
required: { }
|
||||
required:
|
||||
- farm_migrate_role
|
||||
optional:
|
||||
- farm_migrate_system_date
|
||||
|
|
Loading…
Reference in a new issue