Commit Graph

492 Commits

Author SHA1 Message Date
Feanil Patel
88c7cd7bf3 feat!: Remove Legacy Preview Functionality (#36460)
* feat!: Remove all trivial mentions of PREVIEW_LMS_BASE

There are a few more mentions but these are all the ones that don't need
major further followup.

BREAKING CHANGE: The learning MFE now supports preview functionality
natively and it is no longer necessary to use a different domain on the
LMS to render a preview of course content.

See https://github.com/openedx/frontend-app-learning/issues/1455 for
more details.

* feat: Drop the `in_preview_mode` function.

Since we're no longer using a separate domain, that check always
returned false.  Remove it and update any places/tests where it is used.

* feat: Drop courseware_mfe_is_active function.

With the removal of the preview check this function is also a no-op now
so drop calls to it and update the places where it is called to not
change other behavior.

* feat!: Drop redirect to preview from the legacy courseware index.

The CoursewareIndex view is going to be removed eventually but for now
we're focusing on removing the PREVIEW_LMS_BASE setting.  With this
change, if someone tries to load the legacy courseware URL from the
preview domain it will no longer redirect them to the MFE preview.

This is not a problem that will occur for users coming from existing
studio links because those links have already been updated to go
directly to the new urls.

The only way this path could execute is if someone goes directly to the
old Preview URL that they saved off platform somewhere.  eg. If they
bookmarked it for some reason.

BREAKING CHANGE: Saved links (including bookmarks) to the legacy preview
URLs will no longer redirect to the MFE preview URLs.

* test: Drop the set_preview_mode test helper.

This test helper was setting the preview mode for tests by changing the
hostname that was set while tests were running.  This was mostly not
being used to test preview but to run a bunch of legacy courseware tests
while defaulting to the new learning MFE for the courseware.

This commit updates various tests in the `courseware` app to not rely on
the fact that we're in preview to test legacy courseware behavior and
instead directly patches either the `_redirect_to_learning_mfe` function
or uses the `_get_legacy_courseware_url` or both to be able to have the
tests continue to test the legacy coursewary.

This will hopefully make the tests more accuarte even though hopefully
we'll just be removing many of them soon as a part of the legacy
courseware cleanup.

We're just doing the preview removal separately to reduce the number of
things that are changing at once.

* test: Drop the `_get_urls_function`

With the other recent cleanup, this function is no longer being
referenced by anything so we can just drop it.

* test: Test student access to unpublihsed content.

Ensure that students can't get access to unpublished content.
2025-05-14 08:59:11 -04:00
Feanil Patel
1829eb7d71 feat!: Remove the course sock and related APIs.
DEPR: https://github.com/openedx/edx-platform/issues/36429

This change removes the course_sock and related API data.  The UI it
removes is on the Legacy Courseware pages which have also been replaced
and have their own [deprecation ticket](https://github.com/openedx/edx-platform/issues/35803)

Before this can be merged, we will need to update the
frontend-app-learning MFE to no longer consume the
`can_show_upgrade_sock` attribute.

BREAKING CHANGE: CourseHomeMetadata, ProgressTab, OutlineTab and
VerifiedMode APIs will no longer have a `can_show_upgrade_sock`
attribute.
2025-04-07 10:29:39 -04:00
Deborah Kaplan
29de9b2dc4 feat!: Legacy account, profile, order history removal (#36219)
* feat!: Legacy account, profile, order history removal

This removes the legacy account and profile applications, and the order
history page. This is primarily a reapplication of #31893, which was
rolled back due to prior blockers.

FIXES: APER-3884
FIXES: openedx/public-engineering#71


Co-authored-by: Muhammad Abdullah Waheed <42172960+abdullahwaheed@users.noreply.github.com>
Co-authored-by: Bilal Qamar <59555732+BilalQamar95@users.noreply.github.com>
2025-02-10 14:39:13 -05:00
Marcos
67a56c270f chore: Moved jwt file to openedx.core.lib 2025-01-23 15:55:58 -03:00
Marcos
3bcbcaac2d chore: Removed unused dependency 2025-01-23 15:55:58 -03:00
Marcos
825931a9b4 chore: Removed edx-token-utils dep and moved necessary logic to the repo 2025-01-23 15:55:58 -03:00
Muhammad Farhan Khan
f9126bfdd9 Add Django settings flags to roll out the extracted XBlocks (#35549)
chore: Add Django settings flags to roll out the extracted XBlocks
2024-12-02 20:38:40 +05:00
Alison Langston
139b4167b3 feat: update logic for courseware search enabled endpoint (#35922) 2024-11-25 10:44:49 -05:00
Kristin Aoki
e13d66d1e4 feat: support unit preview in learning MFE (#35747)
* feat: update preview url to direct to mfe

* fix: use url builder instead of string formatter

* fix: url redirect for never published units

* fix: remove 404 error when  not a preview or staff

* feat: update sequence metadata to allow draft branch
2024-11-01 11:03:06 -04:00
Alison Langston
338a0a1166 feat: check course start date for courseware search (#35740) 2024-10-30 08:52:43 -04:00
Kristin Aoki
afd1394112 Revert "feat: update preview url to direct to mfe (#35687)" (#35732)
This reverts commit 2373dd02f9.
2024-10-28 17:26:29 +00:00
Kristin Aoki
2373dd02f9 feat: update preview url to direct to mfe (#35687)
* feat: update preview url to direct to mfe

* fix: use url builder instead of string formatter

* fix: url redirect for never published units
2024-10-28 10:31:53 -04:00
Régis Behmo
bf862d89e7 feat!: hide courses in /courses based on catalog visibility
Previously, courses were always displayed on the LMS /courses page,
independently of their catalog visibility attribute. This meant that
even with visibility="none" courses were being displayed. This was very
counter-intuitive.

With this change, courses are displayed only when their visibility is
set to "both".

This change is flagged as breaking because it has the potential to
affect course catalogs in existing platforms.

To test this change, go to http(s)://LMS/courses as an anonymous user.
Pick a visible course and go to its "advanced settings" in the studio.
Set "Course visibility in catalog" to "about" or "none". Then, clear the
cache with the following command:

    ./manage.py lms shell -c "from django.core.cache import cache; cache.clear()"

Open the /courses page again: the course should no longer be visible.

Close https://github.com/openedx/wg-build-test-release/issues/330
2024-10-16 10:03:46 -04:00
Mohammad Ahtasham ul Hassan
6a63cfcaa4 feat: add override option to upgrade CTA utils and add course_run_key identifier (#35441)
* feat: add override option to upgrade CTAs and send course_run_key identifier
2024-09-16 13:15:51 +05:00
Nathan Sprenkle
deb5b0f038 feat: add filter to hook render of XBlock (#34865)
* Bumps openedx-filters to 1.9.0
* Adds filter to hook render of XBlock
* Disables a too-many-statements warning on render_xblock function
2024-06-25 11:17:20 -04:00
Deborah Kaplan
68b052620a Merge branch 'master' into bleach#33209 2024-06-10 11:27:12 -04:00
Juliana Kang
cb52915370 fix: Financial Assistance Letter extend time to award and styling edits (#34913)
REV-4066
2024-06-06 16:41:54 -04:00
Irtaza Akram
f7229e0aad chore: replace bleach with nh3 2024-05-28 13:02:16 +05:00
Ivan Niedielnitsev
333f1ff2c2 feat: [FC-0056] Add waffle flags for navigation and auxiliary (discussion and notification) sidebars (#34650)
Add waffle flags for navigation and auxiliary (discussion and notification) sidebars.
---------

Co-authored-by: Glib Glugovskiy <glib.glugovskiy@raccoongang.com>
Co-authored-by: Glib Glugovskiy <glugov1998@gmail.com>
Co-authored-by: Adolfo R. Brandes <arbrandes@arbrand.es>
2024-05-06 11:04:51 -03:00
Zachary Hancock
3852358ca2 feat: feature setting to gate courseware search to verified enrollments (#34606)
Adds a Django setting that limits courseware search to users in a verified enrollment track.
2024-04-25 11:41:53 -04:00
Chris Pappas
4a2e7c72b4 chore: add logging to fa form (#34224)
* chore: add logging to fa form

* chore: formatting
2024-02-12 18:28:41 -05:00
Chris Pappas
2e15d69c33 fix: give FA form user friendly error message (#34222) 2024-02-12 16:14:09 -05:00
Chris Pappas
accfdccb7f fix: require email verification on FA form (#34219)
fix: broken test lms/djangoapps/courseware/tests/test_views.py

fix: refactor test
2024-02-12 15:09:19 -05:00
Navin Karkera
4a46ae9902 feat: filter courses by user language by default (#33647)
Adds a feature flag to filter courses by users preferred language by default
2024-02-07 08:53:04 +10:30
Juliana Kang
01f60b54e5 feat: Financial assistance form learner privacy update (#33808)
REV-2764
2023-12-08 10:59:45 -05:00
Muhammad Abdullah Waheed
caf8e456e2 Revert "feat: Account and profile MFE legacy removal - redeployment (#31893)" (#33542)
This reverts commit 08f5e7e563.
2023-10-19 12:26:29 +05:00
Muhammad Abdullah Waheed
08f5e7e563 feat: Account and profile MFE legacy removal - redeployment (#31893)
feat: Account and profile MFE legacy removal - redeployment

* Revert "Revert "FC-0001: Account pages -> micro-frontend (#30336)" (#31888)"

This reverts commit 90c4ca6e47.

* refactor: removed filters test from user_api accounts

---------

Co-authored-by: Bilal Qamar <59555732+BilalQamar95@users.noreply.github.com>
2023-10-19 10:43:15 +05:00
Marcos
5bc0a575b8 feat: Added Waffle Flags for Courseware Search feature 2023-10-04 12:19:32 -03:00
Artur Gaspar
7da99848a7 fix: edxnotes visibility in courseware and courseware API (#33096)
This retrieves user preferences for edxnotes visibility by:
1. Adding a `bind_course_for_student` method to course overview model.
2. Using a bound XBlock in the `toggle_notes.html` template.

The previously used unbound course instance was returning a default value.
2023-09-07 17:59:51 +02:00
Agrendalath
92b684004e refactor: reuse services and wrappers between XBlocks (fixed)
This re-applies commit 36cc415 with handling an invalid context_key in the
`PartitionService`. It can happen when rendering a `LibraryContentBlock` in
Studio because this service is initialized by the modulestore when validating
an XBlock to gather its error messages in the `studio_xblock_wrapper`.
2023-07-19 18:01:59 +02:00
Piotr Surowiec
c6bd98e51a Revert "refactor: reuse services and wrappers between XBlocks" (#32730)
This reverts commit 36cc415fc2.
2023-07-13 10:05:34 -04:00
Agrendalath
36cc415fc2 refactor: reuse services and wrappers between XBlocks 2023-06-30 15:06:43 +02:00
Leangseu Kim
1b50e80437 chore: add go to course button for student already enrolled in the courses
chore: linting

chore: update requested change
2023-05-30 09:45:50 -04:00
Leangseu Kim
ee3a854d14 chore: update og:url for video sharing 2023-05-18 10:41:30 -04:00
Nathan Sprenkle
745cda1580 feat: course overrides of video sharing settings (#32169)
* refactor: public sharing enabled toggle

Cherry-picked from https://github.com/openedx/edx-platform/pull/32150

* feat: course video share setting on video block

Adds awareness of course.video_sharing_options setting to video XBlock.
This can override whether or not sharing is enabled for a video or fall
back to per-video settings

* test: course video share setting on video block

Adds awareness of course.video_sharing_options setting to video XBlock.
This can override whether or not sharing is enabled for a video or fall
back to per-video settings

* test: course video share setting on preview page

Extends checking for course override of video share settings to public
video preview page.
2023-05-03 13:23:34 -04:00
Pooja Kulkarni
c80fba689a refactor: rename descriptor -> block within lms/djangoapps/courseware
Co-authored-by: Agrendalath <piotr@surowiec.it>
2023-04-26 17:10:53 +02:00
Kaustav Banerjee
c5439221cb chore: address review comments 2023-04-21 11:53:49 +02:00
Jansen Kantor
cfc0e43eeb fix: remove field filtering on catalog lookup (#32022)
* fix: remove field filtering on catalog lookup

* style: quality
2023-04-03 15:22:39 +00:00
Jansen Kantor
0ec8939eac fix: owner -> owners (#32016) 2023-03-31 14:49:18 +00:00
Jansen Kantor
2f64020259 feat: get info from catalog service (#32009) 2023-03-30 12:01:51 -04:00
Jansen Kantor
da1982f432 fix: get marketing url from overview, with override (#31998)
* fix: get marketing url from overview, with override

* style: quality
2023-03-28 16:02:36 -04:00
Jansen Kantor
035bd6ae2d fix: allow iframe embed v2 (#31983) 2023-03-23 14:42:52 -04:00
Jansen Kantor
c319b55f9c fix: xframe options (#31981) 2023-03-23 10:22:41 -04:00
Nathan Sprenkle
4d999ed3f7 feat: add organization logo to public video page (#31922)
* feat: add org logo to public video page

Refactors CTA banner slightly to allow for left org logo float.

* fix: hide org logo if not provided

* test: add tests for org logo
2023-03-16 10:35:02 -04:00
Jansen Kantor
b6ba32830a feat: add endpoint to tell if video sharing feature is enabled for a course (#31931)
* feat: add endpoint to tell if video sharing feature is enabled for a course

* feat: create video setting endpoint

* feat: move toggle out of lms

* docs: update toggle location in comment

* docs: fix toggle annotation
2023-03-16 09:51:05 -04:00
Muhammad Abdullah Waheed
90c4ca6e47 Revert "FC-0001: Account pages -> micro-frontend (#30336)" (#31888)
This reverts commit 0f02c7b3d9.
2023-03-07 17:41:56 -05:00
Jansen Kantor
ef30d2d32e feat: add cta buttons to public video xblock page
* feat: video share page buttons
* feat: pass along utm params
* feat: disbale register button on public video page
* fix: convert to class-based view
2023-03-07 14:24:27 -05:00
Sagirov Evgeniy
0f02c7b3d9 FC-0001: Account pages -> micro-frontend (#30336)
* feat: Account pages. Learner Profile page

* feat: Account pages. Account Settings page

* feat: Account pages. Removed unused styles

* feat: Account pages. Removed unused toggles

* feat: fixed tests and pylint errors

* feat: update redirect to account settings for student_dashboard

* feat: fix pylint errors
2023-03-07 17:41:52 +05:00
Jansen Kantor
e809344701 fix: waffle flag gates public video (#31881)
* fix: waffle flag gates public video

* test: move test into existing file
2023-03-06 15:16:22 -05:00
Jansen Kantor
d6f1fd54ac fix: video share improvements (#31792)
* feat: show poster thumbnail for social media preview

* fix: hide video downloads in public_view

* fixup! fix: hide video downloads in public_view

* test: fix failing video tests
2023-02-17 17:35:34 -05:00