Merge pull request #53674 from frappe/mergify/bp/version-15-hotfix/pr-53673

fix: stock queue for SABB (backport #53673)
This commit is contained in:
rohitwaghchaure
2026-03-22 13:20:05 +05:30
committed by GitHub

View File

@@ -748,11 +748,16 @@ class SerialandBatchBundle(Document):
precision = frappe.get_precision("Serial and Batch Entry", "incoming_rate")
for d in self.entries:
fifo_batch_wise_val = True
if valuation_method == "FIFO" and d.batch_no in batches:
fifo_batch_wise_val = False
if self.is_rejected and not set_valuation_rate_for_rejected_materials:
rate = 0.0
elif (
(flt(d.incoming_rate, precision) == flt(rate, precision))
and not stock_queue
and fifo_batch_wise_val
and d.qty
and d.stock_value_difference
):