fix: update inventory dimensions before returning sle
This commit is contained in:
parent
31ed4ef6d6
commit
e6a02719f7
@ -397,6 +397,7 @@ class StockReconciliation(StockController):
|
|||||||
"voucher_type": self.doctype,
|
"voucher_type": self.doctype,
|
||||||
"voucher_no": self.name,
|
"voucher_no": self.name,
|
||||||
"voucher_detail_no": row.name,
|
"voucher_detail_no": row.name,
|
||||||
|
"actual_qty": flt(row.current_qty),
|
||||||
"company": self.company,
|
"company": self.company,
|
||||||
"stock_uom": frappe.db.get_value("Item", row.item_code, "stock_uom"),
|
"stock_uom": frappe.db.get_value("Item", row.item_code, "stock_uom"),
|
||||||
"is_cancelled": 1 if self.docstatus == 2 else 0,
|
"is_cancelled": 1 if self.docstatus == 2 else 0,
|
||||||
@ -406,8 +407,6 @@ class StockReconciliation(StockController):
|
|||||||
}
|
}
|
||||||
)
|
)
|
||||||
|
|
||||||
self.update_inventory_dimensions(row, data)
|
|
||||||
|
|
||||||
if not row.batch_no:
|
if not row.batch_no:
|
||||||
data.qty_after_transaction = flt(row.qty, row.precision("qty"))
|
data.qty_after_transaction = flt(row.qty, row.precision("qty"))
|
||||||
|
|
||||||
@ -425,6 +424,8 @@ class StockReconciliation(StockController):
|
|||||||
data.valuation_rate = flt(row.valuation_rate)
|
data.valuation_rate = flt(row.valuation_rate)
|
||||||
data.stock_value_difference = -1 * flt(row.amount_difference)
|
data.stock_value_difference = -1 * flt(row.amount_difference)
|
||||||
|
|
||||||
|
self.update_inventory_dimensions(row, data)
|
||||||
|
|
||||||
return data
|
return data
|
||||||
|
|
||||||
def make_sle_on_cancel(self):
|
def make_sle_on_cancel(self):
|
||||||
|
Loading…
x
Reference in New Issue
Block a user