Update product.php

This commit is contained in:
Laurent Destailleur 2018-01-20 12:53:30 +01:00 committed by GitHub
parent a58a3f893d
commit 23494a9dd4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -111,7 +111,7 @@ $parameters=array('id'=>$id, 'ref'=>$ref, 'objcanvas'=>$objcanvas);
$reshook=$hookmanager->executeHooks('doActions',$parameters,$object,$action); // Note that $action and $object may have been modified by some hooks
if ($reshook < 0) setEventMessages($hookmanager->error, $hookmanager->errors, 'errors');
if ($action == 'addlimitstockwarehouse' AND !empty($user->rights->produit->creer))
if ($action == 'addlimitstockwarehouse' && !empty($user->rights->produit->creer))
{
$seuil_stock_alerte = GETPOST('seuil_stock_alerte');
@ -155,7 +155,7 @@ if ($action == 'addlimitstockwarehouse' AND !empty($user->rights->produit->creer
}
if($action == 'delete_productstockwarehouse' AND !empty($user->rights->produit->creer))
if($action == 'delete_productstockwarehouse' && !empty($user->rights->produit->creer))
{
$pse = new ProductStockEntrepot($db);
@ -167,7 +167,7 @@ if($action == 'delete_productstockwarehouse' AND !empty($user->rights->produit->
}
// Set stock limit
if ($action == 'setseuil_stock_alerte' AND !empty($user->rights->produit->creer))
if ($action == 'setseuil_stock_alerte' && !empty($user->rights->produit->creer))
{
$object = new Product($db);
$result=$object->fetch($id);
@ -181,7 +181,7 @@ if ($action == 'setseuil_stock_alerte' AND !empty($user->rights->produit->creer)
}
// Set desired stock
if ($action == 'setdesiredstock' AND !empty($user->rights->produit->creer))
if ($action == 'setdesiredstock' && !empty($user->rights->produit->creer))
{
$object = new Product($db);
$result=$object->fetch($id);