[Master] - What If Impact on Planning and Supply#9196
Draft
v-rohangarg20 wants to merge 1 commit into
Draft
Conversation
|
@v-rohangarg20 please read the following Contributor License Agreement(CLA). If you agree with the CLA, please reply with the following information.
Contributor License AgreementContribution License AgreementThis Contribution License Agreement (“Agreement”) is agreed to by the party signing below (“You”),
|
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 Slice 636114: [master] [all-e] What-if analysis — Analyze negative impact of supply changes on demand
Fixes AB#636114
Issue: When a planner reduces the quantity, delays, or cancels a supply document (purchase / production / transfer order), there is no way to preview which downstream demand (production orders, transfer orders, sales orders) will be negatively impacted before committing the change. Today the planner must make the change, re-run planning, and manually compare the results.
Cause: No direct link exists between a supply document and the dependent demand it covers — the impact can only be traced by re-running the full planning engine and comparing reservations. There was no programmatic "what breaks if this supply line changes?" primitive to surface it up front.
Solution: Added a "What-If" action on the purchase / production / transfer order subforms that opens a simulation. New codeunit 5455 "Supply What-If Planning Engine" (with temp tables "Supply What-If Scenario" and "What-If Impact", and the "Supply What-If Scenarios" / "What-If Impacts" pages) runs the existing planning engine in preview mode — CarryOutActionMsgPlan.SetSimulationMode against the user's temporary requisition worksheet lines — reads the impacted outbound reservations, and lists the affected documents, all without persisting any change. Also guards invalid input (no change to simulate, What-If Qty > Original, What-If Date < Original). Phase 1 covers negative scenarios and 1-level direct impact; validated with 11 new tests in SCMPlanningAndManufacturing.Codeunit.al.