Skip to content

Commit

Permalink
fix(test): test_auto_create_purchase_receipt
Browse files Browse the repository at this point in the history
  • Loading branch information
s-aga-r committed Nov 29, 2023
1 parent 7b0cd03 commit 3da0aa6
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -574,6 +574,8 @@ def make_purchase_receipt(source_name, target_doc=None, save=False, submit=False
ignore_child_tables=True,
)

target_doc.currency = frappe.get_cached_value("Company", target_doc.company, "default_currency")

po_items_details = {}
for item in source_doc.items:
if item.purchase_order and item.purchase_order_item:
Expand All @@ -586,6 +588,7 @@ def make_purchase_receipt(source_name, target_doc=None, save=False, submit=False
item_row = {
"item_code": po_item.item_code,
"item_name": po_item.item_name,
"conversion_factor": conversion_factor,
"qty": flt(item.qty) * conversion_factor,
"rejected_qty": flt(item.rejected_qty) * conversion_factor,
"uom": po_item.uom,
Expand Down

0 comments on commit 3da0aa6

Please sign in to comment.