Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closes #1946 Embedded images in demo content are not found #2995

Merged
merged 1 commit into from
Dec 6, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions modules/custom/az_demo/data/az_demo_image_file.json
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,7 @@
"title": ""
},
{
"uuid": "5cec161c-71bc-4d23-824f-a692400ee17a",
"filename" : "arizona_campus_fireworks.jpg",
"alt" : "Fireworks over campus",
"title": ""
Expand Down Expand Up @@ -151,6 +152,12 @@
"filename" : "gmo.jpg",
"alt" : "Concept of research on genetic modification of food",
"title": ""
},
{
"filename" : "sea-anemone.jpg",
"alt" : "A close-up image of a vibrant sea anemone under water. The anemone's long, slender tentacles are colored in varying shades of blue and tipped with yellow, creating a striking contrast. Partially hidden among the tentacles, a clownfish with its characteristic orange and white stripes can be seen, adding a sense of life and movement to the scene. The background is a blur of marine colors, indicating a complex reef environment.",
"title" : "Clownfish Peekaboo in a Sea Anemone",
"uuid": "6c01643a-9935-4317-874f-5fd0a29fad26"
}
]
}
Expand Down
7 changes: 7 additions & 0 deletions modules/custom/az_demo/migrations/az_demo_image_file.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,9 @@ source:
type: string

fields:
-
name: uuid
selector: uuid
-
name: filename
selector: filename
Expand All @@ -31,6 +34,10 @@ source:
destination:
plugin: 'entity:media'
process:
uuid:
plugin: skip_on_empty
method: process
source: uuid
bundle:
plugin: default_value
default_value: az_image
Expand Down