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

Fix replacement of service pictogram paths with absolute URLs in API #3579

Merged
merged 6 commits into from
May 9, 2023

Conversation

marcantoinedupre
Copy link
Contributor

@marcantoinedupre marcantoinedupre commented Apr 25, 2023

Also expand to 'description_teaser' and 'ambiance' fields.

Should address issue #3321

@cypress
Copy link

cypress bot commented Apr 25, 2023

Passing run #6440 ↗︎

0 24 0 0 Flakiness 0

Details:

Merge 4d153e4 into c5bd8ec...
Project: Geotrek-admin Commit: 381190b4f8 ℹ️
Status: Passed Duration: 03:46 💡
Started: May 9, 2023 4:31 PM Ended: May 9, 2023 4:35 PM

This comment has been generated by cypress-bot as a result of this project's GitHub integration settings.

@codecov
Copy link

codecov bot commented Apr 25, 2023

Codecov Report

Patch coverage: 100.00% and project coverage change: -0.01 ⚠️

Comparison is base (c5bd8ec) 98.31% compared to head (4d153e4) 98.31%.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #3579      +/-   ##
==========================================
- Coverage   98.31%   98.31%   -0.01%     
==========================================
  Files         292      292              
  Lines       21549    21548       -1     
==========================================
- Hits        21185    21184       -1     
  Misses        364      364              
Impacted Files Coverage Δ
geotrek/api/v2/serializers.py 99.89% <100.00%> (-0.01%) ⬇️

☔ View full report in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

@marcantoinedupre marcantoinedupre requested a review from a team April 25, 2023 16:19
geotrek/api/v2/serializers.py Outdated Show resolved Hide resolved
geotrek/api/v2/serializers.py Outdated Show resolved Hide resolved
The previous fix was not complete. When getting a trek description from the API, if img src is a path it is now transformed into a URL using the protocol and hostname from the API request.
Make the replacement method class-internal + move it out of serializer methods.
@marcantoinedupre marcantoinedupre force-pushed the fix-service-pictogram-url branch from 5598f4a to 4ae9540 Compare May 9, 2023 15:50
@marcantoinedupre marcantoinedupre merged commit 47e61b8 into master May 9, 2023
@marcantoinedupre marcantoinedupre deleted the fix-service-pictogram-url branch May 9, 2023 16:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants