Merge pull request #13404 from hregis/10.0_mc2

FIX remove unused var, $usercancreate can be change by Multicompany
This commit is contained in:
Laurent Destailleur 2020-03-23 15:13:19 +01:00 committed by GitHub
commit 04a875f43b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -53,7 +53,6 @@ $socid=GETPOST('socid', 'int');
$cost_price=GETPOST('cost_price', 'alpha'); $cost_price=GETPOST('cost_price', 'alpha');
$backtopage=GETPOST('backtopage', 'alpha'); $backtopage=GETPOST('backtopage', 'alpha');
$error=0; $error=0;
$canmodifyotherentityfournprice = 1 ;
// If socid provided by ajax company selector // If socid provided by ajax company selector
if (! empty($_REQUEST['search_fourn_id'])) if (! empty($_REQUEST['search_fourn_id']))
@ -936,7 +935,7 @@ SCRIPT;
// Modify-Remove // Modify-Remove
print '<td class="center nowraponall">'; print '<td class="center nowraponall">';
if ($usercancreate && $canmodifyotherentityfournprice == 1) if ($usercancreate)
{ {
print '<a href="'.$_SERVER['PHP_SELF'].'?id='.$object->id.'&amp;socid='.$productfourn->fourn_id.'&amp;action=add_price&amp;rowid='.$productfourn->product_fourn_price_id.'">'.img_edit()."</a>"; print '<a href="'.$_SERVER['PHP_SELF'].'?id='.$object->id.'&amp;socid='.$productfourn->fourn_id.'&amp;action=add_price&amp;rowid='.$productfourn->product_fourn_price_id.'">'.img_edit()."</a>";
print ' &nbsp; '; print ' &nbsp; ';