Files
edx-platform/lms/djangoapps/course_home_api/utils.py
Nicholas D'Alfonso 0709977785 AA-117 mfe date tab waffle flag
- create master course home waffle flag
- create course waffle flag for accessing the mfe dates tab
2020-05-29 12:34:43 -04:00

16 lines
404 B
Python

"""Utility functions for course home"""
from django.conf import settings
def get_microfrontend_url(course_key, view_name=None):
"""
Takes in a course key and view name, returns the appropriate course home mfe route
"""
mfe_link = '{}/course/{}'.format(settings.LEARNING_MICROFRONTEND_URL, course_key)
if view_name:
mfe_link += '/{}'.format(view_name)
return mfe_link