We have add the following stock report but it show the Quantity is more than what shows available on the warehouse
we need the qty exactly what is available on the warehouse
SELECT
sle.item_code,
item.item_name,
sle.warehouse,
SUM(CASE WHEN sle.actual_qty > 0 THEN sle.actual_qty ELSE 0 END) - SUM(CASE WHEN sle.actual_qty < 0 THEN sle.actual_qty ELSE 0 END) AS available_qty
FROM
tabStock Ledger Entry
as sle
JOIN
tabItem
as item ON sle.item_code = item.name
WHERE
sle.actual_qty > 0
AND sle.company = %(company)s
GROUP BY
sle.item_code, item.item_name, sle.warehouse;