fix: use stock qty to calculate POS reserved stock (#33735)

This commit is contained in:
Xeanth
2023-01-22 19:36:01 +07:00
committed by GitHub
parent 7a8e89e2fe
commit ad437fd5ba

View File

@@ -675,7 +675,7 @@ def get_bin_qty(item_code, warehouse):
def get_pos_reserved_qty(item_code, warehouse):
reserved_qty = frappe.db.sql(
"""select sum(p_item.qty) as qty
"""select sum(p_item.stock_qty) as qty
from `tabPOS Invoice` p, `tabPOS Invoice Item` p_item
where p.name = p_item.parent
and ifnull(p.consolidated_invoice, '') = ''