diff --git a/README.rst b/README.rst index e831d9b6..fed97b4c 100644 --- a/README.rst +++ b/README.rst @@ -11,6 +11,7 @@ In addition, this plugin comes with a few MFEs which are enabled by default: - `Course Authoring `__ - `Discussions `__ - `Gradebook `__ +- `Learner Dashboard `__ - `Learning `__ - `ORA Grading `__ - `Profile `__ @@ -86,6 +87,14 @@ Gradebook This instructor-only MFE is for viewing individual and aggregated grade results for a course. To access this MFE, go to a course → Instructor tab → Student Admin → View gradebook. The URL should be: ``http(s)://{{ MFE_HOST }}/gradebook/{{ course ID }}``. When running locally, the gradebook of the demo course is available at: http://apps.local.overhang.io/gradebook/course-v1:edX+DemoX+Demo_Course +Learner Dashboard +~~~~~~~~~~~~~~~~~ + +.. image:: https://raw.githubusercontent.com/overhangio/tutor-mfe/master/screenshots/learner-dashboard.png + :alt: Learner Dashboard MFE screenshot + +The Learner Dashboard MFE provides a clean and functional interface to allow learners to view all of their open enrollments, as well as take relevant actions on those enrollments. + Learning ~~~~~~~~ diff --git a/changelog.d/20231116_110038_arbrandes_add_learner_dashboard.md b/changelog.d/20231116_110038_arbrandes_add_learner_dashboard.md new file mode 100644 index 00000000..e5c319a4 --- /dev/null +++ b/changelog.d/20231116_110038_arbrandes_add_learner_dashboard.md @@ -0,0 +1 @@ +- [Feature] Add support for the Learner Dashboard MFE. (by @arbrandes) diff --git a/screenshots/learner-dashboard.png b/screenshots/learner-dashboard.png new file mode 100644 index 00000000..a94c00ee Binary files /dev/null and b/screenshots/learner-dashboard.png differ diff --git a/tutormfe/patches/openedx-lms-common-settings b/tutormfe/patches/openedx-lms-common-settings index 49d7674f..db372aba 100644 --- a/tutormfe/patches/openedx-lms-common-settings +++ b/tutormfe/patches/openedx-lms-common-settings @@ -10,5 +10,7 @@ MFE_CONFIG_API_CACHE_TIMEOUT = 1 FEATURES['ENABLE_AUTHN_MICROFRONTEND'] = True {% elif app_name == "communications" %} FEATURES['ENABLE_NEW_BULK_EMAIL_EXPERIENCE'] = True +{% elif app_name == "learner-dashboard" %} +LEARNER_HOME_MFE_REDIRECT_PERCENTAGE = 100 {% endif %} {% endfor %} diff --git a/tutormfe/patches/openedx-lms-development-settings b/tutormfe/patches/openedx-lms-development-settings index 31cfb4e2..d968e44b 100644 --- a/tutormfe/patches/openedx-lms-development-settings +++ b/tutormfe/patches/openedx-lms-development-settings @@ -40,6 +40,8 @@ DISCUSSIONS_MICROFRONTEND_URL = "http://{{ MFE_HOST }}:{{ app["port"] }}/discuss DISCUSSIONS_MFE_FEEDBACK_URL = None {% elif app_name == "gradebook" %} WRITABLE_GRADEBOOK_URL = "http://{{ MFE_HOST }}:{{ app["port"] }}/gradebook" +{% elif app_name == "learner-dashboard" %} +LEARNER_HOME_MICROFRONTEND_URL = "http://{{ MFE_HOST }}:{{ app["port"] }}/learner-dashboard" {% elif app_name == "learning" %} LEARNING_MICROFRONTEND_URL = "http://{{ MFE_HOST }}:{{ app["port"] }}/learning" MFE_CONFIG["LEARNING_BASE_URL"] = "http://{{ MFE_HOST }}:{{ app["port"] }}" diff --git a/tutormfe/patches/openedx-lms-production-settings b/tutormfe/patches/openedx-lms-production-settings index 38870aa7..ae295a99 100644 --- a/tutormfe/patches/openedx-lms-production-settings +++ b/tutormfe/patches/openedx-lms-production-settings @@ -40,6 +40,8 @@ DISCUSSIONS_MICROFRONTEND_URL = "{% if ENABLE_HTTPS %}https://{% else %}http://{ DISCUSSIONS_MFE_FEEDBACK_URL = None {% elif app_name == "gradebook" %} WRITABLE_GRADEBOOK_URL = "{% if ENABLE_HTTPS %}https://{% else %}http://{% endif %}{{ MFE_HOST }}/gradebook" +{% elif app_name == "learner-dashboard" %} +LEARNER_HOME_MICROFRONTEND_URL = "{% if ENABLE_HTTPS %}https://{% else %}http://{% endif %}{{ MFE_HOST }}/learner-dashboard" {% elif app_name == "learning" %} LEARNING_MICROFRONTEND_URL = "{% if ENABLE_HTTPS %}https://{% else %}http://{% endif %}{{ MFE_HOST }}/learning" MFE_CONFIG["LEARNING_BASE_URL"] = "{{ "https" if ENABLE_HTTPS else "http" }}://{{ MFE_HOST }}/learning" diff --git a/tutormfe/plugin.py b/tutormfe/plugin.py index 4433b0c2..8eca080b 100644 --- a/tutormfe/plugin.py +++ b/tutormfe/plugin.py @@ -69,6 +69,11 @@ def get_github_refs_path(name: str) -> str: "refs": get_github_refs_path("openedx/frontend-app-gradebook"), "port": 1994, }, + "learner-dashboard": { + "repository": "https://github.com/openedx/frontend-app-learner-dashboard", + "refs": get_github_refs_path("openedx/frontend-app-learner-dashboard"), + "port": 1996, + }, "learning": { "repository": "https://github.com/openedx/frontend-app-learning", "refs": get_github_refs_path("openedx/frontend-app-learning"), diff --git a/tutormfe/templates/mfe/tasks/lms/init b/tutormfe/templates/mfe/tasks/lms/init index 9e6db52b..85a652ce 100644 --- a/tutormfe/templates/mfe/tasks/lms/init +++ b/tutormfe/templates/mfe/tasks/lms/init @@ -16,6 +16,12 @@ site-configuration unset --domain={{ LMS_HOST }}:8000 ENABLE_PROFILE_MICROFRONTE ./manage.py lms waffle_delete --flags learner_profile.redirect_to_microfrontend {% endif %} +{% if is_mfe_enabled("learner-dashboard") %} +(./manage.py lms waffle_flag --list | grep learner_home_mfe.enabled) || ./manage.py lms waffle_flag learner_home_mfe.enabled --create --everyone +{% else %} +./manage.py lms waffle_delete --flags learner_home_mfe.enabled +{% endif %} + {% if is_mfe_enabled("learning") %} (./manage.py lms waffle_flag --list | grep course_home.course_home_mfe_progress_tab) || ./manage.py lms waffle_flag --create --everyone course_home.course_home_mfe_progress_tab {% else %}