Merge branch '10.0' of git@github.com:Dolibarr/dolibarr.git into 11.0
Conflicts: htdocs/fourn/class/fournisseur.commande.class.php
This commit is contained in:
commit
08aa3eac00
@ -3173,6 +3173,7 @@ class CommandeFournisseur extends CommonOrder
|
||||
{
|
||||
if (is_array($supplierorderdispatch->lines) && count($supplierorderdispatch->lines) > 0)
|
||||
{
|
||||
require_once DOL_DOCUMENT_ROOT.'/htdocs/product/class/product.class.php';
|
||||
$date_liv = dol_now();
|
||||
|
||||
// Build array with quantity deliverd by product
|
||||
@ -3180,7 +3181,11 @@ class CommandeFournisseur extends CommonOrder
|
||||
$qtydelivered[$line->fk_product] += $line->qty;
|
||||
}
|
||||
foreach ($this->lines as $line) {
|
||||
$qtywished[$line->fk_product] += $line->qty;
|
||||
if ($line->product_type == Product::TYPE_PRODUCT ||
|
||||
($line->product_type == Product::TYPE_SERVICE && !empty($conf->global->STOCK_SUPPORTS_SERVICES))
|
||||
) {
|
||||
$qtywished[$line->fk_product] += $line->qty;
|
||||
}
|
||||
}
|
||||
//Compare array
|
||||
$diff_array = array_diff_assoc($qtydelivered, $qtywished); // Warning: $diff_array is done only on common keys.
|
||||
|
||||
Loading…
Reference in New Issue
Block a user