fix(procurement-dashboard): display readable status labels in overview card#5908
Merged
Conversation
…ng human readable
weimiao67
approved these changes
Jul 8, 2026
Contributor
|
🎉 This PR is included in version 1.426.2 🎉 The release is available on GitHub release Your semantic-release bot 📦🚀 |
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 changed
Fixes the Procurement Dashboard summary page rendering raw enum strings (e.g.
IN_EXECUTION) instead of human-readable labels (e.g.Executing) in the Procurement Overview card's stacked bar legend.frontend/src/pages/procurementDashboard/summary/ProcurementOverviewCard.jsxconvertCodeForDisplayto the import fromutilsbuildStatusData, replaceditem.label(the raw enum value from the API) withconvertCodeForDisplay("budgetLineStatus", item.status), which uses the existing frontend mapping to produce readable display namesitem.label === "In Execution"ternary in the render that never fired (the label was"IN_EXECUTION", not"In Execution")The backend's
item.labelfield has always been set tostatus.value(the raw enum string) since the function was introduced in commitab6573420— it was never human-readable. The frontend mapping inconvertCodeForDisplayalready has the correct display names and is used consistently everywhere else statuses are shown.Issue
#5902
How to test
docker compose up --build)Planned,Executing, andObligatedinstead ofPLANNED,IN_EXECUTION, andOBLIGATEDTo run the relevant unit tests:
A11y impact
Storybook
Screenshots
Fixing the label fixed both problems

Definition of Done Checklist
Links
N/A