Fix issue #22846
This commit is contained in:
parent
cdcd54e6fe
commit
482775cd38
@ -91,7 +91,7 @@ if ($module == 'propal') {
|
||||
} elseif ($module == 'shipping') {
|
||||
$permission = $user->hasRight("expedition", "creer");
|
||||
} elseif ($module == 'product') {
|
||||
$permission = $user->hasRight("produit", "creer");
|
||||
$permission = $user->hasRight("product", "creer");
|
||||
} elseif ($module == 'service') {
|
||||
$permission = $user->hasRight("service", "creer");
|
||||
} elseif ($module == 'ecmfiles') {
|
||||
|
||||
@ -54,13 +54,13 @@ $permissionnote = $user->rights->produit->creer; // Used by the include of actio
|
||||
|
||||
if ($object->id > 0) {
|
||||
if ($object->type == $object::TYPE_PRODUCT) {
|
||||
restrictedArea($user, 'produit', $object->id, 'product&product', '', '');
|
||||
restrictedArea($user, 'product', $object->id, 'product&product', '', '');
|
||||
}
|
||||
if ($object->type == $object::TYPE_SERVICE) {
|
||||
restrictedArea($user, 'service', $object->id, 'product&product', '', '');
|
||||
}
|
||||
} else {
|
||||
restrictedArea($user, 'produit|service', $fieldvalue, 'product&product', '', '', $fieldtype);
|
||||
restrictedArea($user, 'product|service', $fieldvalue, 'product&product', '', '', $fieldtype);
|
||||
}
|
||||
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user