Loading src/Form/MigrateSandboxForm.php +7 −1 Original line number Diff line number Diff line Loading @@ -187,10 +187,16 @@ class MigrateSandboxForm extends ConfigFormBase { '#default_value' => $default_destination, '#description' => $this->t('Either way, the result is stored only temporarily. No entity will be saved.'), ]; if (is_array($this->config('migrate_sandbox.latest')->get('destination.plugin'))) { $entity_type_default = explode(':', $this->config('migrate_sandbox.latest')->get('destination.plugin'))[1] ?? 'node'; } else { $entity_type_default = 'node'; } $form['destination_wrapper']['entity_type'] = [ '#type' => 'textfield', '#title' => $this->t('Entity type (e.g. node or taxonomy_term)'), '#default_value' => explode(':', $this->config('migrate_sandbox.latest')->get('destination.plugin'))[1] ?? 'node', '#default_value' => $entity_type_default, '#states' => [ 'visible' => [ ':input[name="destination"]' => ['value' => 'entity'], Loading Loading
src/Form/MigrateSandboxForm.php +7 −1 Original line number Diff line number Diff line Loading @@ -187,10 +187,16 @@ class MigrateSandboxForm extends ConfigFormBase { '#default_value' => $default_destination, '#description' => $this->t('Either way, the result is stored only temporarily. No entity will be saved.'), ]; if (is_array($this->config('migrate_sandbox.latest')->get('destination.plugin'))) { $entity_type_default = explode(':', $this->config('migrate_sandbox.latest')->get('destination.plugin'))[1] ?? 'node'; } else { $entity_type_default = 'node'; } $form['destination_wrapper']['entity_type'] = [ '#type' => 'textfield', '#title' => $this->t('Entity type (e.g. node or taxonomy_term)'), '#default_value' => explode(':', $this->config('migrate_sandbox.latest')->get('destination.plugin'))[1] ?? 'node', '#default_value' => $entity_type_default, '#states' => [ 'visible' => [ ':input[name="destination"]' => ['value' => 'entity'], Loading