Skip to content

Commit

Permalink
fix: check item_code in all rows of po_items (backport #31741) (#31842)
Browse files Browse the repository at this point in the history
fix: check item_code in all rows of po_items (#31741)

fix: check the item code in each row of PO items
(cherry picked from commit 0047e18)

Co-authored-by: Sagar Sharma <sagarsharma.s312@gmail.com>
  • Loading branch information
mergify[bot] and s-aga-r authored Aug 14, 2022
1 parent c3fd802 commit 82f1dd2
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -639,6 +639,9 @@ def get_sub_assembly_items(self, manufacturing_type=None):
sub_assembly_items_store = [] # temporary store to process all subassembly items

for row in self.po_items:
if not row.item_code:
frappe.throw(_("Row #{0}: Please select Item Code in Assembly Items").format(row.idx))

bom_data = []
get_sub_assembly_items(row.bom_no, bom_data, row.planned_qty)
self.set_sub_assembly_items_based_on_level(row, bom_data, manufacturing_type)
Expand Down

0 comments on commit 82f1dd2

Please sign in to comment.