Feat: Show email delivery status on ContractAdminPage seat table - #3733
Open
daniellefrappier18 wants to merge 3 commits into
Open
Feat: Show email delivery status on ContractAdminPage seat table#3733daniellefrappier18 wants to merge 3 commits into
daniellefrappier18 wants to merge 3 commits into
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
Adds per-seat email delivery status to the contract administration seat table.
Changes:
- Displays delivery states with status-specific pills and an accessible failure tooltip.
- Updates status labels and CSV exports.
- Upgrades the MITx Online API client and related factories.
Reviewed changes
Copilot reviewed 7 out of 8 changed files in this pull request and generated 5 comments.
Show a summary per file
| File | Description |
|---|---|
yarn.lock |
Locks the upgraded API client. |
frontends/main/package.json |
Upgrades the MITx Online client. |
frontends/api/package.json |
Upgrades shared API dependency. |
ContractAdminPage.tsx |
Adds delivery-status display and export logic. |
ContractAdminPage.test.tsx |
Tests status pills and updated labels. |
OrganizationCards.test.tsx |
Adds the required SSO organization field. |
factories/organization.ts |
Supplies the new organization field. |
factories/contracts.ts |
Supplies email-status fields. |
Suppressed comments (1)
frontends/main/src/app-pages/ContractAdminPage/ContractAdminPage.test.tsx:919
- Filtering
getByTextwith the internal.MuiChip-labelclass couples this test to MUI markup, contrary to the frontend testing guideline to query by role/label/text rather than classes. Scope the visible “Pending” assertion to its table row or status cell using semantic queries.
expect(
screen.getByText("Pending", { selector: ".MuiChip-label" }),
).toBeInTheDocument()
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
…eries, Failed-pill focus coverage, drop resolved sso_organization_id workaround
OpenAPI ChangesNo changes detected Unexpected changes? Ensure your branch is up-to-date with |
dsubak
self-requested a review
August 10, 2026 23:47
This file contains hidden or 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
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.
What are the relevant tickets?
Description (What does it do?)
Replaces the binary "Pending claim"/"Redeemed" status pill on the Contract Admin seat table with the new per-seat email delivery status (
Pending/Delivered/Opened/Clicked/Failed), while keeping "Redeemed" behavior unchanged.getDisplayStatus()mergesredemption_status+email_statusinto one displayed value:redeemedalways wins; otherwise a null/"pending"email_statuscollapses to plain "Pending," anddelivered/opened/clickedrender as "Pending - X" since the seat is still unredeemed.Screenshots (if appropriate):
How can this be tested?
Local-dev testing walkthrough (Tilt / ol-infrastructure)
This assumes the feat/openedx-tilt-local-dev k3d+Tilt stack from ol-infrastructure, with mitxonline enabled. A couple of things surfaced while I was testing this that are worth calling out to whoever picks this up:
Setup
yarn installafter pulling this branch — it bumps@mitodl/mitxonline-api-axiosto2026.8.6.kubectl config current-context→local-dev.DiscountContractAttachmentRedemptionrow you'll edit below.Fastest path — verify every pill/color/tooltip directly (bypasses email sending entirely):
Find the record's id:
Then set whichever status you want to check (pending, delivered, opened, clicked, or failed):
Refresh ContractAdminPage and confirm: correct label text ("Pending", "Pending - Delivered/Opened/Clicked", or "Failed"), correct pill color, and — for failed — the warning icon and tooltip (hover and keyboard-focus the pill; the explanation should be announced as a description, not replace the "Failed" name).
Additional Context