Skip to content

Commit

Permalink
fix: update dashboard recommendations endpoint (openedx#33072)
Browse files Browse the repository at this point in the history
- Update recommendations endpoint from learner recommendations to edx recommendations.
- Added docstring to tell contributors that the recommendations related code has been moved to edx-recommendations plugin.

VAN-1596
  • Loading branch information
mubbsharanwar authored Aug 23, 2023
1 parent 7ae64a5 commit 6eba79a
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
3 changes: 3 additions & 0 deletions lms/djangoapps/learner_recommendations/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,9 @@

class AboutPageRecommendationsView(APIView):
"""
IMPORTANT: Please do not update or use this API. This code has been moved to edx-recommendations plugin.
Please use that plugin for further code changes. This API will be removed as part of VAN-1427.
**Example Request**
GET api/learner_recommendations/amplitude/{course_id}/
Expand Down
2 changes: 1 addition & 1 deletion lms/static/js/learner_dashboard/RecommendationsPanel.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ class RecommendationsPanel extends React.Component {
};

getCourseList = async () => {
const coursesRecommendationData = await fetch(`${this.props.lmsRootUrl}/api/learner_recommendations/courses/`)
const coursesRecommendationData = await fetch(`${this.props.lmsRootUrl}/api/edx_recommendations/learner_dashboard/amplitude/`)
.then(response => response.json())
.catch(() => ({
courses: this.props.generalRecommendations,
Expand Down

0 comments on commit 6eba79a

Please sign in to comment.