@@ -84,6 +84,7 @@ class modMyModule extends DolibarrModules
...
@@ -84,6 +84,7 @@ class modMyModule extends DolibarrModules
// 'css' => array('/mymodule/css/mymodule.css.php'), // Set this to relative path of css file if module has its own css file
// 'css' => array('/mymodule/css/mymodule.css.php'), // Set this to relative path of css file if module has its own css file
// 'js' => array('/mymodule/js/mymodule.js'), // Set this to relative path of js file if module must load a js on all pages
// 'js' => array('/mymodule/js/mymodule.js'), // Set this to relative path of js file if module must load a js on all pages
// 'hooks' => array('hookcontext1','hookcontext2') // Set here all hooks context managed by module
// 'hooks' => array('hookcontext1','hookcontext2') // Set here all hooks context managed by module
// 'dir' => array('output' => 'othermodulename'), // To force the default directories names
// 'workflow' => array('WORKFLOW_MODULE1_YOURACTIONTYPE_MODULE2'=>array('enabled'=>'! empty($conf->module1->enabled) && ! empty($conf->module2->enabled)', 'picto'=>'yourpicto@mymodule')) // Set here all workflow context managed by module
// 'workflow' => array('WORKFLOW_MODULE1_YOURACTIONTYPE_MODULE2'=>array('enabled'=>'! empty($conf->module1->enabled) && ! empty($conf->module2->enabled)', 'picto'=>'yourpicto@mymodule')) // Set here all workflow context managed by module
public$modules=array();// List of activated modules
public$modules=array();// List of activated modules
public$modules_parts=array('css'=>array(),'js'=>array(),'triggers'=>array(),'login'=>array(),'substitutions'=>array(),'menus'=>array(),'theme'=>array(),'tpl'=>array(),'barcode'=>array(),'models'=>array(),'hooks'=>array());// List of modules parts
public$modules_parts=array('css'=>array(),'js'=>array(),'triggers'=>array(),'login'=>array(),'substitutions'=>array(),'menus'=>array(),'theme'=>array(),'tpl'=>array(),'barcode'=>array(),'models'=>array(),'hooks'=>array(),'dir'=>array());// List of modules parts
// TODO Remove thoose arrays with generic module_parts
// TODO Remove thoose arrays with generic module_parts
public$tabs_modules=array();
public$tabs_modules=array();
...
@@ -258,6 +258,7 @@ class Conf
...
@@ -258,6 +258,7 @@ class Conf
// Define default dir_output and dir_temp for directories of modules
// Define default dir_output and dir_temp for directories of modules
if(($user->rights->$modulepart->lire)||($user->rights->$modulepart->read)||($user->rights->$modulepart->download))$accessallowed=1;// No subpermission, we have checked on main permission
if(($user->rights->$modulepart->lire)||($user->rights->$modulepart->read)||($user->rights->$modulepart->download))$accessallowed=1;// No subpermission, we have checked on main permission
elseif(preg_match('/^specimen/i',$original_file))$accessallowed=1;// If link to a specimen
elseif(preg_match('/^specimen/i',$original_file))$accessallowed=1;// If link to a specimen