From 3a8f479db7df5fdcb5af8c45a23050c5aebb9d1f Mon Sep 17 00:00:00 2001 From: Anthony Berton <34568357+bb2a@users.noreply.github.com> Date: Mon, 27 Jun 2022 11:16:50 +0200 Subject: [PATCH] Update card.php --- htdocs/expedition/card.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/htdocs/expedition/card.php b/htdocs/expedition/card.php index 384f2cdde3d..f79e4becd9d 100644 --- a/htdocs/expedition/card.php +++ b/htdocs/expedition/card.php @@ -1197,7 +1197,7 @@ if ($action == 'create') { if (count($warehousePicking) == 1 || !($line->fk_product > 0) || empty($conf->stock->enabled)) { // If warehouse was already selected or if product is not a predefined, we go into this part with no multiwarehouse selection print ''; //ship from preselected location - $stock = + isSET($product->stock_warehouse[$warehouse_id]->real) ? $product->stock_warehouse[$warehouse_id]->real : 0; // Convert to number + $stock = + isset($product->stock_warehouse[$warehouse_id]->real) ? $product->stock_warehouse[$warehouse_id]->real : 0; // Convert to number $deliverableQty = min($quantityToBeDelivered, $stock); if ($deliverableQty < 0) { $deliverableQty = 0;