mirror of
https://github.com/frappe/erpnext.git
synced 2026-10-29 22:57:42 +00:00
Merge pull request #62935 from khushi8112/fix/pi-stock-value-precision
fix(accounts): post an invoice's stock at the unrounded valuation rate
This commit is contained in:
@@ -642,10 +642,9 @@ class PurchaseInvoiceGLComposer(BaseGLComposer):
|
||||
def make_stock_adjustment_entry(self, gl_entries, item, voucher_wise_stock_value, account_currency):
|
||||
doc = self.doc
|
||||
net_amt_precision = item.precision("base_net_amount")
|
||||
val_rate_db_precision = 6 if cint(item.precision("valuation_rate")) <= 6 else 9
|
||||
|
||||
warehouse_debit_amount = flt(
|
||||
flt(item.valuation_rate, val_rate_db_precision) * get_stock_qty(item, item.qty),
|
||||
flt(item.valuation_rate) * get_stock_qty(item, item.qty),
|
||||
net_amt_precision,
|
||||
)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user