mirror of
https://github.com/frappe/erpnext.git
synced 2026-06-04 04:39:11 +00:00
fix precision in stock entry (#14366)
This commit is contained in:
@@ -263,7 +263,7 @@ class StockEntry(StockController):
|
|||||||
d.actual_qty = previous_sle.get("qty_after_transaction") or 0
|
d.actual_qty = previous_sle.get("qty_after_transaction") or 0
|
||||||
|
|
||||||
# validate qty during submit
|
# validate qty during submit
|
||||||
if d.docstatus==1 and d.s_warehouse and not allow_negative_stock and d.actual_qty < d.transfer_qty:
|
if d.docstatus==1 and d.s_warehouse and not allow_negative_stock and flt(d.actual_qty, d.precision("actual_qty")) < flt(d.transfer_qty, d.precision("actual_qty")):
|
||||||
frappe.throw(_("Row {0}: Qty not available for {4} in warehouse {1} at posting time of the entry ({2} {3})").format(d.idx,
|
frappe.throw(_("Row {0}: Qty not available for {4} in warehouse {1} at posting time of the entry ({2} {3})").format(d.idx,
|
||||||
frappe.bold(d.s_warehouse), formatdate(self.posting_date),
|
frappe.bold(d.s_warehouse), formatdate(self.posting_date),
|
||||||
format_time(self.posting_time), frappe.bold(d.item_code))
|
format_time(self.posting_time), frappe.bold(d.item_code))
|
||||||
|
|||||||
Reference in New Issue
Block a user