Merge pull request #1961 from FHenry/3.6
Fix right and error management
This commit is contained in:
commit
3528049348
@ -422,10 +422,10 @@ if (empty($reshook))
|
|||||||
$_error++;
|
$_error++;
|
||||||
$action = "";
|
$action = "";
|
||||||
|
|
||||||
$mesg='<div class="error">'.$langs->trans("ErrorProductAlreadyExists",$object->ref);
|
$mesg=$langs->trans("ErrorProductAlreadyExists",$object->ref);
|
||||||
$mesg.=' <a href="'.$_SERVER["PHP_SELF"].'?ref='.$object->ref.'">'.$langs->trans("ShowCardHere").'</a>.';
|
$mesg.=' <a href="'.$_SERVER["PHP_SELF"].'?ref='.$object->ref.'">'.$langs->trans("ShowCardHere").'</a>.';
|
||||||
$mesg.='</div>';
|
|
||||||
setEventMessage($mesg, 'errors');
|
setEventMessage($mesg, 'errors');
|
||||||
|
$object->fetch($id);
|
||||||
//dol_print_error($object->db);
|
//dol_print_error($object->db);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
|||||||
@ -467,7 +467,7 @@ else
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Better buy price
|
// Better buy price
|
||||||
if ($user->rights->produit->creer)
|
if ($user->rights->fournisseur->lire)
|
||||||
{
|
{
|
||||||
print '<td align="right">';
|
print '<td align="right">';
|
||||||
if ($objp->minsellprice != '')
|
if ($objp->minsellprice != '')
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user