Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
WCMS
uw_migrate
Commits
2daec0d0
Commit
2daec0d0
authored
Sep 15, 2021
by
Chris Shantz
Browse files
Merge branch '1.0.x' into prod/1.0.x
parents
786d306f
cd5a3b1f
Changes
3
Hide whitespace changes
Inline
Side-by-side
migrations/uw_url_alias.yml
→
migrations/uw_url_alias
_node
.yml
View file @
2daec0d0
...
...
@@ -9,24 +9,12 @@ source:
plugin
:
d7_url_alias
constants
:
slash
:
'
/'
slashnode
:
'
/node/'
base
:
'
/node/'
conditions
:
-
field
:
ua.source
value
:
'
%node/%'
operator
:
LIKE
process
:
_alias_type
:
-
plugin
:
explode
source
:
source
delimiter
:
'
/'
-
plugin
:
single_value
-
plugin
:
extract
index
:
-
0
-
plugin
:
skip_on_value
method
:
row
value
:
'
node'
not_equals
:
true
new_nid
:
-
plugin
:
explode
...
...
@@ -59,7 +47,7 @@ process:
path
:
plugin
:
concat
source
:
-
constants/
slashnod
e
-
constants/
bas
e
-
'
@new_nid'
alias
:
plugin
:
concat
...
...
migrations/uw_url_alias_taxonomy.yml
0 → 100644
View file @
2daec0d0
id
:
uw_url_alias_taxonomy
label
:
URL aliases (Taxonomy terms)
migration_group
:
uw
migration_tags
:
-
Drupal
7
-
Content
-
Etc
source
:
plugin
:
d7_url_alias
constants
:
slash
:
'
/'
base
:
'
/taxonomy/term/'
conditions
:
-
field
:
source
value
:
'
%taxonomy/term/%'
operator
:
LIKE
process
:
new_tid
:
-
plugin
:
explode
source
:
source
delimiter
:
'
/'
-
plugin
:
single_value
-
plugin
:
extract
index
:
-
'
2'
default
:
0
-
plugin
:
skip_on_empty
method
:
row
-
plugin
:
migration_lookup
migration
:
-
uw_taxonomy_term
no_stub
:
true
-
plugin
:
skip_on_empty
method
:
row
path
:
plugin
:
concat
source
:
-
constants/base
-
'
@new_tid'
alias
:
plugin
:
concat
source
:
-
constants/slash
-
alias
langcode
:
language
destination
:
plugin
:
entity:path_alias
migration_dependencies
:
required
:
{}
optional
:
-
uw_taxonomy_term
src/Plugin/migrate/source/UwWebform.php
View file @
2daec0d0
...
...
@@ -3,6 +3,7 @@
namespace
Drupal\uw_migrate\Plugin\migrate\source
;
use
Drupal\uw_migrate
\
UwWebformTrait
;
use
Drupal\webform\Plugin\WebformHandler\EmailWebformHandler
;
use
Drupal\webform\Utility\WebformYaml
;
use
Drupal\webform_migrate
\
Plugin\migrate\source\d7\D7Webform
;
use
Drupal\Component\Utility\Bytes
;
...
...
@@ -502,6 +503,22 @@ class UwWebform extends D7Webform {
];
}
// Convert "default" to "_default". See webform_update_8131().
$default_settings
=
[
'to_mail'
,
'from_mail'
,
'from_name'
,
'subject'
,
'body'
,
];
foreach
(
array_keys
(
$handlers
)
as
$id
)
{
foreach
(
$default_settings
as
$setting
)
{
if
(
$handlers
[
$id
][
'settings'
][
$setting
]
===
'default'
)
{
$handlers
[
$id
][
'settings'
][
$setting
]
=
EmailWebformHandler
::
DEFAULT_VALUE
;
}
}
}
return
$handlers
;
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment