[Master] - Bug 641222: Sustainability - Show CO2e per unit on Item Journal line#9563
Draft
v-rohangarg20 wants to merge 1 commit into
Draft
[Master] - Bug 641222: Sustainability - Show CO2e per unit on Item Journal line#9563v-rohangarg20 wants to merge 1 commit into
v-rohangarg20 wants to merge 1 commit into
Conversation
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.
Workitem Bug 641222: [Sustainability] Item Journal line shows only Total CO2e; CO2e per Unit is not visible/editable without Page Inspector
Fixes AB#641222
Issue: On the Item Journal, only "Total CO2e" was shown on the line. The "CO2e per Unit" value could not be seen or edited from the page — users had to open Page Inspector to view/change it, making per‑unit emission entry impractical.
Cause: The "CO2e per Unit" field (field 6217 on the Item Journal Line) existed on the table and was fully functional (with its own OnValidate that recalculates Total CO2e), but it was never added to the "Sust. Item Journal" page extension layout. Only "Total CO2e" had a control.
Solution: Added a "CO2e per Unit" field control to the "Sust. Item Journal" page extension, placed just before "Total CO2e". It reuses the existing SustainabilityVisible visibility toggle and Basic, Suite application area, so it appears (and is editable) only when value chain tracking is enabled — consistent with the other sustainability fields. Editing it now drives the existing Total CO2e recalculation directly from the journal, with no need for Page Inspector.