Skip to content

feat: decouple enterprise from courseware view redirects, course start-date validation, and course access checks - #38102

Merged
pwnage101 merged 3 commits into
masterfrom
pwnage101/ENT-11544
Jun 25, 2026
Merged

feat: decouple enterprise from courseware view redirects, course start-date validation, and course access checks#38102
pwnage101 merged 3 commits into
masterfrom
pwnage101/ENT-11544

Conversation

@pwnage101

@pwnage101 pwnage101 commented Mar 5, 2026

Copy link
Copy Markdown
Contributor
  • Instead of an enterprise-specific view decorator conditionally redirecting learners to a consent view, plugins can now hook into the CoursewareViewStarted filter to redirect anywhere.
  • Instead of enterprise-specific logic throwing an enterprise-specific start date validation error, CourseStartDateValidationFailed filter can now be used by plugins to throw a custom start date error.
  • Instead of enterprise/consent-specific access checks baked into check_course_access, the CoursewareAccessChecksRequested filter lets plugins deny courseware access with a generic priority access error.

ENT-11544


Blocked by:

@pwnage101 pwnage101 added the enterprise An enterprise-related change label Mar 18, 2026
@pwnage101
pwnage101 force-pushed the pwnage101/ENT-11544 branch 5 times, most recently from f09f36f to 6f251ba Compare May 20, 2026 01:11
@pwnage101
pwnage101 force-pushed the pwnage101/ENT-11544 branch from 6f251ba to 3760bd3 Compare May 21, 2026 16:46
@pwnage101
pwnage101 force-pushed the pwnage101/ENT-11544 branch 6 times, most recently from 1133be1 to 6ab7a92 Compare June 2, 2026 22:51
@pwnage101 pwnage101 changed the title feat: replace DSC decorator and enterprise imports in courseware feat: decouple enterprise from courseware view redirects, course start-date validation, and course access checks Jun 2, 2026
@pwnage101
pwnage101 force-pushed the pwnage101/ENT-11544 branch 12 times, most recently from 9c69294 to 83a0815 Compare June 9, 2026 02:47
Instead of an enterprise-specific view decorator conditionally
redirecting learners to a consent view, plugins can now hook into the
CoursewareViewStarted filter to redirect anywhere.

ENT-11544
@pwnage101
pwnage101 force-pushed the pwnage101/ENT-11544 branch from 83a0815 to 774ec22 Compare June 24, 2026 21:44
@pwnage101
pwnage101 marked this pull request as ready for review June 24, 2026 23:11
@pwnage101
pwnage101 force-pushed the pwnage101/ENT-11544 branch from 2ec66c8 to 539cd92 Compare June 24, 2026 23:26
Instead of enterprise-specific logic throwing an enterprise-specific
start date validation error, CourseStartDateValidationFailed filter can
now be used by plugins to throw a custom start date error.

ENT-11544
Instead of enterprise/consent-specific access checks baked into
check_course_access, the CoursewareAccessChecksRequested filter lets
plugins deny courseware access with a generic priority access error.

This also removes orphaned utility functions from enterprise_support:

* consent_needed_for_course
* get_enterprise_consent_url
* get_active_enterprise_customer_user

ENT-11544
@pwnage101
pwnage101 force-pushed the pwnage101/ENT-11544 branch from 539cd92 to c578f56 Compare June 24, 2026 23:27
@pwnage101
pwnage101 merged commit b85f12a into master Jun 25, 2026
46 checks passed
@pwnage101
pwnage101 deleted the pwnage101/ENT-11544 branch June 25, 2026 17:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enterprise An enterprise-related change

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants