-
Notifications
You must be signed in to change notification settings - Fork 7.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: Dont set idx
while adding WO items to Stock Entry
#30377
Merged
Merged
Conversation
This file contains 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
- `idx` must be computed by base document's `self.append()` function, so do not set it
Codecov Report
@@ Coverage Diff @@
## develop #30377 +/- ##
============================================
+ Coverage 36.80% 60.83% +24.02%
============================================
Files 1081 1082 +1
Lines 68920 69059 +139
============================================
+ Hits 25367 42010 +16643
+ Misses 43553 27049 -16504
|
- idx can be removed from `select_columns` as it is already in the main query - setting idx to '' is not required as it is not used further
af152cc
to
639d380
Compare
ankush
added a commit
that referenced
this pull request
Mar 30, 2022
…0377) (#30485) * fix: Dont set `idx` while adding WO items to Stock Entry - `idx` must be computed by base document's `self.append()` function, so do not set it (cherry picked from commit a787ebb) # Conflicts: # erpnext/stock/doctype/stock_entry/stock_entry.py * chore: Remove redundant idx query and value setting - idx can be removed from `select_columns` as it is already in the main query - setting idx to '' is not required as it is not used further (cherry picked from commit 639d380) # Conflicts: # erpnext/stock/doctype/stock_entry/stock_entry.py * test: idx mapping correctness (cherry picked from commit fa3b953) * fix: Linter (cherry picked from commit b5ad626) * fix: resolve conflicts Co-authored-by: marination <maricadsouza221197@gmail.com> Co-authored-by: Ankush Menat <ankush@frappe.io>
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
Issue:
Create a BOM of the foll.g structure:
Now create a WO, with Skip Material Transfer = 1
Finish the WO, the Manufacture Stock Entry will have wrong idx

Fix:
add_stock_entry_detail()
, remove idx mappingidx
must be auto-computed by base document'sself.append()
function, so do not set itToDo: