diff --git a/include/stock_overview.php b/include/stock_overview.php index 039c8dec..5b4660c6 100644 --- a/include/stock_overview.php +++ b/include/stock_overview.php @@ -118,6 +118,8 @@ function box_state_id_from_filter($applied_filter) products as b ON upper(a.name)=upper(b.name) WHERE a.camp_id = :camp_id and b.camp_id = :camp_id and a.id<=b.id + AND (NOT a.deleted OR a.deleted IS NULL) + AND (NOT b.deleted OR b.deleted IS NULL) GROUP BY upper(a.name) ) prod_a