FIX CVE Need permission to be able to develop modules
This commit is contained in:
parent
d60ce8a2c3
commit
1c24bcc724
@ -45,6 +45,7 @@ class modModuleBuilder extends DolibarrModules
|
|||||||
// Family can be 'crm','financial','hr','projects','products','ecm','technic','other'
|
// Family can be 'crm','financial','hr','projects','products','ecm','technic','other'
|
||||||
// It is used to group modules in module setup page
|
// It is used to group modules in module setup page
|
||||||
$this->family = "technic";
|
$this->family = "technic";
|
||||||
|
$this->module_position = '90';
|
||||||
// Module label (no space allowed), used if translation string 'ModuleXXXName' not found (where XXX is value of numeric property 'numero' of module)
|
// Module label (no space allowed), used if translation string 'ModuleXXXName' not found (where XXX is value of numeric property 'numero' of module)
|
||||||
$this->name = preg_replace('/^mod/i', '', get_class($this));
|
$this->name = preg_replace('/^mod/i', '', get_class($this));
|
||||||
$this->description = "A RAD (Rapid Application Development) tool to help developers to build their own module.";
|
$this->description = "A RAD (Rapid Application Development) tool to help developers to build their own module.";
|
||||||
@ -82,6 +83,21 @@ class modModuleBuilder extends DolibarrModules
|
|||||||
//------
|
//------
|
||||||
$this->boxes = array();
|
$this->boxes = array();
|
||||||
|
|
||||||
|
// Permissions
|
||||||
|
//------------
|
||||||
|
$this->rights = array(); // Permission array used by this module
|
||||||
|
$this->rights_class = 'modulebuilder';
|
||||||
|
|
||||||
|
$r=0;
|
||||||
|
|
||||||
|
$r++;
|
||||||
|
$this->rights[$r][0] = 3301;
|
||||||
|
$this->rights[$r][1] = 'Generate new modules';
|
||||||
|
$this->rights[$r][2] = 'a';
|
||||||
|
$this->rights[$r][3] = 0;
|
||||||
|
$this->rights[$r][4] = 'run';
|
||||||
|
|
||||||
|
|
||||||
// Main menu entries
|
// Main menu entries
|
||||||
//------------------
|
//------------------
|
||||||
$this->menu = array();
|
$this->menu = array();
|
||||||
|
|||||||
@ -90,6 +90,9 @@ if (empty($newmask)) // This should no happen
|
|||||||
$newmask = '0664';
|
$newmask = '0664';
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$result = restrictedArea($user, 'modulebuilder', null);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Actions
|
* Actions
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user