Merge pull request #7500 from dolibarr95/patch-19

Try to fix 7492
This commit is contained in:
Laurent Destailleur
2017-09-26 20:57:37 +02:00
committed by GitHub

View File

@@ -561,6 +561,11 @@ if (empty($reshook))
if (!$res) dol_print_error($db);
}
if ($productsupplier->get_buyprice(0, price2num($_POST['qty']), $line->fk_product, 'none', GETPOST('socid','int')) < 0 )
{
setEventMessages($langs->trans("ErrorQtyTooLowForThisSupplier"), null, 'warnings');
}
$date_start=dol_mktime(GETPOST('date_starthour'), GETPOST('date_startmin'), GETPOST('date_startsec'), GETPOST('date_startmonth'), GETPOST('date_startday'), GETPOST('date_startyear'));
$date_end=dol_mktime(GETPOST('date_endhour'), GETPOST('date_endmin'), GETPOST('date_endsec'), GETPOST('date_endmonth'), GETPOST('date_endday'), GETPOST('date_endyear'));
@@ -677,6 +682,7 @@ if (empty($reshook))
dol_print_error($db,$object->error);
exit;
}
}
// Remove a product line