Skip to content

Chore: Add select query into application#454

Merged
zigzagdev merged 6 commits intochore/add-main_iamge_urlfrom
chore/add-select-query-into-application
May 5, 2026
Merged

Chore: Add select query into application#454
zigzagdev merged 6 commits intochore/add-main_iamge_urlfrom
chore/add-select-query-into-application

Conversation

@zigzagdev
Copy link
Copy Markdown
Owner

No description provided.

zigzagdev and others added 6 commits May 5, 2026 10:58
Adds an optional ?string $mainImageUrl constructor parameter and a
getMainImageUrl() getter so downstream layers can read the raw
main_image_url straight from the DTO.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Reads main_image_url from the input array and forwards it to the
WorldHeritageDto constructor so detail-path callers carry the value.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Reads main_image_url from the input array and forwards it to the
WorldHeritageDto constructor so list/summary callers carry the value.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
…thumbnail

Updates WorldHeritageViewModel::getThumbnailUrl to fall back as
main_image_url ?? images[0]?->url ?? null so the exposed thumbnail_url
reflects the new field. The view model summary test mock is updated to
cover the new path via getMainImageUrl.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Renames the existing 'thumbnail' summary key to 'thumbnail_url' and
fills it with main_image_url ?? images[0]?->url ?? null so the list
endpoint surfaces the new field with the same fallback semantics as
the detail ViewModel. The collection summary test is updated to
assert the new key name.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
WorldHeritageViewModelCollectionFactoryTest used to seed the legacy
imageUrl ImageDto field from thumbnail_url. The view model now resolves
thumbnail_url via main_image_url ?? images[0]?->url, so the mock is
updated to pass mainImageUrl directly. Drops the now-unused ImageDto
import.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@zigzagdev zigzagdev self-assigned this May 5, 2026
Copy link
Copy Markdown
Owner Author

@zigzagdev zigzagdev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok

@zigzagdev zigzagdev merged commit c16a74c into chore/add-main_iamge_url May 5, 2026
25 checks passed
@zigzagdev zigzagdev deleted the chore/add-select-query-into-application branch May 5, 2026 04:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat: Reflect thread main_image_url through DTO and ViewModel with thumbnail fallback

1 participant