From 461bc1733f41de570a4663b0804eb1301d1a346e Mon Sep 17 00:00:00 2001 From: Rohit Waghchaure Date: Sun, 22 Mar 2026 12:06:43 +0530 Subject: [PATCH] fix: stock queue for SABB (cherry picked from commit 3fcf308ed80b3f5a1f1fb5a258fa252fe7b10cb0) --- .../serial_and_batch_bundle/serial_and_batch_bundle.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/erpnext/stock/doctype/serial_and_batch_bundle/serial_and_batch_bundle.py b/erpnext/stock/doctype/serial_and_batch_bundle/serial_and_batch_bundle.py index c3423a5cb59..4de6ebc6a00 100644 --- a/erpnext/stock/doctype/serial_and_batch_bundle/serial_and_batch_bundle.py +++ b/erpnext/stock/doctype/serial_and_batch_bundle/serial_and_batch_bundle.py @@ -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 ):