forked from Wavyzz/dolibarr
correction due to comments @hregis and @eldy
This commit is contained in:
@@ -53,6 +53,7 @@ $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']))
|
||||||
@@ -935,12 +936,6 @@ SCRIPT;
|
|||||||
// Modify-Remove
|
// Modify-Remove
|
||||||
print '<td class="center nowraponall">';
|
print '<td class="center nowraponall">';
|
||||||
|
|
||||||
if (!empty($conf->global->NOTMODIFYOTHERENTITYFOURNPRICE) && $productfourn->product_fourn_entity!=$conf->entity) {
|
|
||||||
$canmodifyotherentityfournprice = 0;
|
|
||||||
}else{
|
|
||||||
$canmodifyotherentityfournprice = 1;
|
|
||||||
}
|
|
||||||
|
|
||||||
if ($usercancreate && $canmodifyotherentityfournprice == 1)
|
if ($usercancreate && $canmodifyotherentityfournprice == 1)
|
||||||
{
|
{
|
||||||
print '<a href="'.$_SERVER['PHP_SELF'].'?id='.$object->id.'&socid='.$productfourn->fourn_id.'&action=add_price&rowid='.$productfourn->product_fourn_price_id.'">'.img_edit()."</a>";
|
print '<a href="'.$_SERVER['PHP_SELF'].'?id='.$object->id.'&socid='.$productfourn->fourn_id.'&action=add_price&rowid='.$productfourn->product_fourn_price_id.'">'.img_edit()."</a>";
|
||||||
|
|||||||
Reference in New Issue
Block a user