From 319063438071b43c102f193f348fc387b65e93d7 Mon Sep 17 00:00:00 2001 From: "Adolfo R. Brandes" Date: Thu, 7 Dec 2023 11:59:58 -0300 Subject: [PATCH 1/2] Fix: Fix get_mfe() usage for learner-dashboard --- tutormfe/patches/openedx-lms-common-settings | 3 ++- tutormfe/patches/openedx-lms-development-settings | 1 - 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/tutormfe/patches/openedx-lms-common-settings b/tutormfe/patches/openedx-lms-common-settings index e8b65fa0..328b25eb 100644 --- a/tutormfe/patches/openedx-lms-common-settings +++ b/tutormfe/patches/openedx-lms-common-settings @@ -10,6 +10,7 @@ FEATURES['ENABLE_AUTHN_MICROFRONTEND'] = True {% endif %} {% if get_mfe("communications") %} FEATURES['ENABLE_NEW_BULK_EMAIL_EXPERIENCE'] = True -{% elif app_name == "learner-dashboard" %} +{% endif %} +{% if get_mfe("learner-dashboard") %} LEARNER_HOME_MFE_REDIRECT_PERCENTAGE = 100 {% endif %} diff --git a/tutormfe/patches/openedx-lms-development-settings b/tutormfe/patches/openedx-lms-development-settings index ea6bf6ee..37e188b2 100644 --- a/tutormfe/patches/openedx-lms-development-settings +++ b/tutormfe/patches/openedx-lms-development-settings @@ -69,7 +69,6 @@ MFE_CONFIG["ACCOUNT_PROFILE_URL"] = "http://{{ MFE_HOST }}:{{ get_mfe("profile") {% if get_mfe("communications") %} COMMUNICATIONS_MICROFRONTEND_URL = "http://{{ MFE_HOST }}:{{ get_mfe("communications")["port"] }}/communications" ->>>>>>> master MFE_CONFIG["SCHEDULE_EMAIL_SECTION"] = True {% endif %} From 15bbd4f06ad4b7619f4ab8f9cc40181e76b581cf Mon Sep 17 00:00:00 2001 From: "Adolfo R. Brandes" Date: Thu, 7 Dec 2023 15:14:36 -0300 Subject: [PATCH 2/2] fix: Fix Account and Learner Dashboard URLs MFEs with URLs that get used "naked" (without any suffixes) require a trailing slash, because that's what our current PUBLIC_PATH setting expects. Without it, these MFEs don't render. --- tutormfe/patches/openedx-lms-development-settings | 4 ++-- tutormfe/patches/openedx-lms-production-settings | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/tutormfe/patches/openedx-lms-development-settings b/tutormfe/patches/openedx-lms-development-settings index 37e188b2..ff227a65 100644 --- a/tutormfe/patches/openedx-lms-development-settings +++ b/tutormfe/patches/openedx-lms-development-settings @@ -31,7 +31,7 @@ MFE_CONFIG["DISABLE_ENTERPRISE_LOGIN"] = True {% endif %} {% if get_mfe("account") %} -ACCOUNT_MICROFRONTEND_URL = "http://{{ MFE_HOST }}:{{ get_mfe("account")["port"] }}/account" +ACCOUNT_MICROFRONTEND_URL = "http://{{ MFE_HOST }}:{{ get_mfe("account")["port"] }}/account/" MFE_CONFIG["ACCOUNT_SETTINGS_URL"] = ACCOUNT_MICROFRONTEND_URL {% endif %} @@ -50,7 +50,7 @@ WRITABLE_GRADEBOOK_URL = "http://{{ MFE_HOST }}:{{ get_mfe("gradebook")["port"] {% endif %} {% if get_mfe("learner-dashboard") %} -LEARNER_HOME_MICROFRONTEND_URL = "http://{{ MFE_HOST }}:{{ get_mfe("learner-dashboard")["port"] }}/learner-dashboard" +LEARNER_HOME_MICROFRONTEND_URL = "http://{{ MFE_HOST }}:{{ get_mfe("learner-dashboard")["port"] }}/learner-dashboard/" {% endif %} {% if get_mfe("learning") %} diff --git a/tutormfe/patches/openedx-lms-production-settings b/tutormfe/patches/openedx-lms-production-settings index c5b0b018..88c6581b 100644 --- a/tutormfe/patches/openedx-lms-production-settings +++ b/tutormfe/patches/openedx-lms-production-settings @@ -32,7 +32,7 @@ MFE_CONFIG["DISABLE_ENTERPRISE_LOGIN"] = True {% endif %} {% if get_mfe("account") %} -ACCOUNT_MICROFRONTEND_URL = "{% if ENABLE_HTTPS %}https://{% else %}http://{% endif %}{{ MFE_HOST }}/account" +ACCOUNT_MICROFRONTEND_URL = "{% if ENABLE_HTTPS %}https://{% else %}http://{% endif %}{{ MFE_HOST }}/account/" MFE_CONFIG["ACCOUNT_SETTINGS_URL"] = ACCOUNT_MICROFRONTEND_URL {% endif %} @@ -51,7 +51,7 @@ WRITABLE_GRADEBOOK_URL = "{% if ENABLE_HTTPS %}https://{% else %}http://{% endif {% endif %} {% if get_mfe("learner-dashboard") %} -LEARNER_HOME_MICROFRONTEND_URL = "{% if ENABLE_HTTPS %}https://{% else %}http://{% endif %}{{ MFE_HOST }}/learner-dashboard" +LEARNER_HOME_MICROFRONTEND_URL = "{% if ENABLE_HTTPS %}https://{% else %}http://{% endif %}{{ MFE_HOST }}/learner-dashboard/" {% endif %} {% if get_mfe("learning") %}