mirror of
https://github.com/frappe/erpnext.git
synced 2026-06-25 03:49:50 +00:00
fix(stock): update voucher valuaion rate in sle (#55960)
(cherry picked from commit 130c2594e1)
Co-authored-by: Sudharsanan Ashok <135326972+Sudharsanan11@users.noreply.github.com>
This commit is contained in:
@@ -916,6 +916,16 @@ class update_entries_after:
|
||||
and not has_dimensions
|
||||
):
|
||||
# assert
|
||||
if (
|
||||
sle.voucher_detail_no
|
||||
and self.repost_doc
|
||||
and self.repost_doc.get("recalculate_valuation_rate")
|
||||
):
|
||||
source_rate = frappe.get_cached_value(
|
||||
"Stock Reconciliation Item", sle.voucher_detail_no, "valuation_rate"
|
||||
)
|
||||
if source_rate:
|
||||
sle.valuation_rate = source_rate
|
||||
self.wh_data.valuation_rate = sle.valuation_rate
|
||||
self.wh_data.qty_after_transaction = sle.qty_after_transaction
|
||||
self.wh_data.stock_value = flt(self.wh_data.qty_after_transaction) * flt(
|
||||
|
||||
Reference in New Issue
Block a user