[Bug]: Manufacturing App – Capacity Measures Fails due to custom Capacity Unit of Measure codes
Nobody has claimed this yet.
- Dominant language
- AL
- Stars
- 683
- Forks
- 459
- Avg merge
- 3d 26m
- Merged PRs (30d)
- 633
Description
Describe the issue
Summary
Capacity-related visuals in the Manufacturing Power BI App return blank values when custom capacity unit of measure codes have been created and used in the Show Capacity In field on the Manufacturing Setup page. The bug is expressed when Show Capacity In is used to lookup values in the Time Factors table in the semantic model.
Problem Description
Several measures use and depend on the selected capacity unit of measure from the Manufacturing Setup table:
VAR SelectedUOM = SELECTEDVALUE('Manufacturing Setup'[Show Capacity In])
The selected value is used in a lookup against the Time Factors table:
VAR TimeFactor = LOOKUPVALUE( 'Time Factors'[Time Factor], 'Time Factors'[Cap Unit of Measure Type], SelectedUOM )
The Time Factors[Cap Unit of Measure Type] column contains values like (Hours, Minutes, Seconds, Days), causing the lookup to fail if the user has created Capacity Unit of Measure records with custom Code values, such as TIMER.
Expected behavior
The capacity measures should work as expected regardless of the Code used in Show Capacity In.
Steps to reproduce
- Create a new Capacity Unit of Measure with the Code = TIMER
- On the Manufacturing Setup page, set Show Capacity In to the new unit of measure code.
- Refresh the Manufacturing semantic model
Additional context
No response
I will provide a fix for a bug
- I will provide a fix for a bug
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the capacity measures in the Manufacturing semantic model and trace how Manufacturing Setup[Show Capacity In] is matched to Time Factors[Cap Unit of Measure Type]. Reproduce the issue with a custom TIMER capacity unit, refresh the model, and verify that capacity visuals return values for custom codes as well as standard units.
Written by the indexing model from the issue text.
Assessment
- Domain
- data-visualization
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 55/100