FIX ordered stock already in $stock
This commit is contained in:
parent
9379f6fa9d
commit
96481c3d52
@ -702,7 +702,10 @@ while ($i < ($limit ? min($num, $limit) : $num))
|
|||||||
|
|
||||||
//depending on conf, use either physical stock or
|
//depending on conf, use either physical stock or
|
||||||
//virtual stock to compute the stock to buy value
|
//virtual stock to compute the stock to buy value
|
||||||
$stocktobuy = max(max($desiredstock, $alertstock) - $stock - $ordered, 0);
|
|
||||||
|
if(empty($usevirtualstock)) $stocktobuy = max(max($desiredstock, $alertstock) - $stock - $ordered, 0);
|
||||||
|
else $stocktobuy = max(max($desiredstock, $alertstock) - $stock, 0); //ordered is already in $stock in virtual mode
|
||||||
|
|
||||||
$disabled = '';
|
$disabled = '';
|
||||||
if ($ordered > 0)
|
if ($ordered > 0)
|
||||||
{
|
{
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user