Skip to content
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

Various fixes/enhancements to support v2 libraries import #105

Merged
merged 5 commits into from
Oct 27, 2023

Conversation

ormsbee
Copy link
Contributor

@ormsbee ormsbee commented Oct 23, 2023

Namely:

  • allows LearningPackages with data in them to be entirely deleted.
  • admin helper for linking to higher level 1:1 models in Django admin–e.g. link from PublishableEntity to Component
  • added get/set_draft_version to publishing API

@ormsbee
Copy link
Contributor Author

ormsbee commented Oct 23, 2023

This is what the admin helper looks like in action:

example_admin_helper

Not having this was causing a surprising amount of friction while I was developing and checking the import command. 😛

@kdmccormick
Copy link
Member

@ormsbee I need to work on testing and merging a different Libraries V2 PR first, but I think can take a look within the next week.

Copy link
Contributor

@bradenmacdonald bradenmacdonald left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! I like your solution for the admin UI.

Created the one_to_one_related_model_html helper to let us link 1:1
models from lower-level models to higher-level ones. So for instance,
"publishing" is a lower level app than "components", meaning that
components can call into publishing, but publishing should have no
awareness of components. But it's really convenient to be able to click
on a PublishableEntity and go to the corresponding Component.

This is even more important as people add more models, potentially
even in edx-platform plugins.
@ormsbee ormsbee merged commit 0d533b8 into openedx:main Oct 27, 2023
6 checks passed
@ormsbee ormsbee deleted the libraries-v2 branch October 27, 2023 14:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants