add program enrollments api and view program certificate button #2439
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.
What are the relevant tickets?
Closes https://github.com/mitodl/hq/issues/8171
Description (What does it do?)
This PR adds the code to query the MITx Online program enrollments API, and sets up the org dashboard to display a button to view your program ceritficate if you have one when displaying a given program.
Screenshots (if appropriate):
How can this be tested?
In order to test this, you need a basic installation of
mitxonline
up and running with example data in it. You may be able to skip one or more steps if you have already done them:hosts
redirects for the following domains, replacing the example IP with your local IP address (Google how to get this if unsure, mine is 192.168.1.50)mitxonline
: https://github.com/mitodl/mitxonline.env
file with the following values:mitxonline
withdocker compose up --build -d
docker compose exec web ./manage.py promote_user promote --superuser --email [email protected]
docker compose exec web ./manage.py populate_course_data
pants docs ::
dist/sphinx/index.html
, read the section on generating a B2B organization / contract and create one, adding some of the test courses to itProgram
and add some courses to the program that are included in your B2B org, making sure to mark the program as "live"mit-learn
, we need to set some env variables:enrollment-dashboard
andmitlearn-organization-dashboard
feature flags for all usersMIT Learn
[email protected]
test userNote that the link will not go anywhere until #2429 is merged. There are also no mobile designs for this particular button, so I just did my best to make sure it renders okay.