-
Notifications
You must be signed in to change notification settings - Fork 48
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: Create django admin for default enrollments #2264
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
brobro10000
force-pushed
the
hu/ent-9579
branch
5 times, most recently
from
October 17, 2024 17:09
f7de046
to
f66b0a0
Compare
brobro10000
force-pushed
the
hu/ent-9579
branch
from
October 18, 2024 13:44
f66b0a0
to
fa7ec13
Compare
brobro10000
force-pushed
the
hu/ent-9579
branch
from
October 18, 2024 14:29
fa7ec13
to
fdbef01
Compare
brobro10000
force-pushed
the
hu/ent-9579
branch
4 times, most recently
from
October 21, 2024 17:44
b4f6afe
to
2e04eab
Compare
brobro10000
commented
Oct 21, 2024
Comment on lines
-1335
to
-1336
'current_course_run_enrollable', | ||
'current_course_run_enroll_by_date', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It was decided for the moment, since the properties on the model are yet to be fleshed out, these fields should be removed.
iloveagent57
approved these changes
Oct 21, 2024
brobro10000
force-pushed
the
hu/ent-9579
branch
3 times, most recently
from
October 22, 2024 03:29
7362a67
to
749651f
Compare
adamstankiewicz
approved these changes
Oct 22, 2024
9 tasks
brobro10000
force-pushed
the
hu/ent-9579
branch
3 times, most recently
from
October 24, 2024 15:12
cbc19fc
to
ee029f7
Compare
* fix: updates to ENT-9579 * Updates Django Admin fields for models.DefaultEnterpriseEnrollmentIntention * Ensures DefaultEnterpriseEnrollmentIntentionAdmin uses SoftDeletableModel's all_objects model manager to be able to view/restore soft-deleted instances. * Adds help text in Django Admin for SoftDeletableModel's is_removed boolean field. * Alters content_type model field to allow blank/null. * Adds unique constraint for enterprise_customer and content_key to prevent duplicates. * Remove `current_*` prefixes on computed properties since a configured content_key might not be the *current* course run. * Updates models.DefaultEnterpriseEnrollmentIntention `clean` method to check for soft-deleted duplicates to raise ValidationError. * Ensures `self.content_type` is already updated on save, even if already set (e.g., if content_key changes to a different content type). * Updates related tests.
brobro10000
force-pushed
the
hu/ent-9579
branch
from
October 24, 2024 15:31
ee029f7
to
a90b0f8
Compare
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Adds a TieredCache call to content metadata's,
get_content_metadata_content_identifier
to determine thecontent_type
of created and updated content. If the content type does not exist, the validation inclean
prevents creation of the inline object.A side effect of including this check is the fleshing out of the
current_course_run
andcurrent_course_run_key
properties on theDefaultEnterpriseEnrollmentIntention
model.Found on the enterprise customer django admin screen,
EnterpriseCustomerDefaultEnterpriseEnrollmentIntentionInline
Cleaned up
EnterpriseCustomerDefaultEnterpriseEnrollment
admin pageMerge checklist:
requirements/*.txt
files)base.in
if needed in production but edx-platform doesn't install ittest-master.in
if edx-platform pins it, with a matching versionmake upgrade && make requirements
have been run to regenerate requirementsmake static
has been run to update webpack bundling if any static content was updated./manage.py makemigrations
has been run./manage.py lms makemigrations
in the shell.Post merge:
(so basically once your build finishes, after maybe a minute you should see the new version in PyPi automatically (on refresh))
make upgrade
in edx-platform will look for the latest version in PyPi.