[SE-3329] Expose banner image url in course API - #260
Merged
gabor-boros merged 1 commit intoSep 25, 2020
Conversation
toxinu
approved these changes
Sep 25, 2020
toxinu
left a comment
There was a problem hiding this comment.
I have already reviewed, tested and approved the upstream PR. Looks good to merge 👍🏻
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR extends the course overview and detail APIs to include (both relative and absolute) banner image url, which allows content publishers to specify a banner image and then reuse that from a custom UI/integration.
Dependencies: None
Upstream PR: https://github.com/edx/edx-platform/pull/25045
Screenshots:
Course which has a banner image

Course which has no banner image

Sandbox URL: https://studio.pr25045.stage.opencraft.hosting/ (Credentials are the usual defaults)
Merge deadline: Preferably 29th of September
Testing instructions:
Course Banner Imagefield into Settings -> Advanced Settings page<URL>/api/courses/v1/courses/to check all the courses, where URL is the sandbox LMS URL<URL>/api/courses/v1/courses/<course_id>to see all the courses, where URL is the sandbox LMS URL and course_id is the course idAuthor notes and concerns:
_AbsolutMediaSerializeris using a private attribute fromAbsoluteURLField, but I found no other way to avoid code duplication and have the same absolute url conversion functionality, sinceAbsoluteURLFieldrequires the request objectCurrently looking for ways to fix it.
Reviewers
Settings