Add new perm to link resource to an element
This commit is contained in:
parent
3a866bd611
commit
1caffcffaf
@ -161,8 +161,8 @@ class modResource extends DolibarrModules
|
|||||||
// (reresource 'x' by type of category (0=product, 1=supplier, 2=customer, 3=member)
|
// (reresource 'x' by type of category (0=product, 1=supplier, 2=customer, 3=member)
|
||||||
|
|
||||||
$this->tabs = array(
|
$this->tabs = array(
|
||||||
'action:+resources:Resources:resource@resource:$user->rights->resource->read:/resource/element_resource.php?element=action&element_id=__ID__',
|
'action:+resources:Resources:resource:$user->rights->resource->read:/resource/element_resource.php?element=action&element_id=__ID__',
|
||||||
'thirdparty:+resources:Resources:resource@resource:$user->rights->resource->read:/resource/element_resource.php?element=societe&element_id=__ID__'
|
'thirdparty:+resources:Resources:resource:$user->rights->resource->read:/resource/element_resource.php?element=societe&element_id=__ID__'
|
||||||
);
|
);
|
||||||
|
|
||||||
/* Example:
|
/* Example:
|
||||||
@ -241,6 +241,12 @@ class modResource extends DolibarrModules
|
|||||||
$this->rights[$r][4] = 'delete';
|
$this->rights[$r][4] = 'delete';
|
||||||
$r++;
|
$r++;
|
||||||
|
|
||||||
|
$this->rights[$r][0] = 1101204;
|
||||||
|
$this->rights[$r][1] = 'Link resources';
|
||||||
|
$this->rights[$r][3] = 0;
|
||||||
|
$this->rights[$r][4] = 'link';
|
||||||
|
$r++;
|
||||||
|
|
||||||
|
|
||||||
// Add here list of permission defined by
|
// Add here list of permission defined by
|
||||||
// an id, a label, a boolean and two constant strings.
|
// an id, a label, a boolean and two constant strings.
|
||||||
@ -270,7 +276,7 @@ class modResource extends DolibarrModules
|
|||||||
'mainmenu'=>'tools',
|
'mainmenu'=>'tools',
|
||||||
'leftmenu'=> 'resource',
|
'leftmenu'=> 'resource',
|
||||||
'url'=> '/resource/index.php',
|
'url'=> '/resource/index.php',
|
||||||
'langs'=> 'resource@resource',
|
'langs'=> 'resource',
|
||||||
'position'=> 100,
|
'position'=> 100,
|
||||||
'enabled'=> '1',
|
'enabled'=> '1',
|
||||||
'perms'=> '$user->rights->resource->read',
|
'perms'=> '$user->rights->resource->read',
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user