NEW Enhance the system for warnings on module activation

This commit is contained in:
ldestailleur
2025-10-10 10:16:33 +02:00
parent a162de2455
commit 3403bbe869
26 changed files with 69 additions and 57 deletions

View File

@@ -163,8 +163,8 @@ class modMyModule extends DolibarrModules
$this->need_javascript_ajax = 0;
// Messages at activation
$this->warnings_activation = array(); // Warning to show when we activate module. array('always'='text') or array('FR'='textfr','MX'='textmx'...)
$this->warnings_activation_ext = array(); // Warning to show when we activate an external module. array('always'='text') or array('FR'='textfr','MX'='textmx'...)
$this->warnings_activation = array(); // Warning to show when we activate a module. Example: array('always'='text') or array('FR'='textfr','MX'='textmx'...)
$this->warnings_activation_ext = array(); // Warning to show when we activate a module if another module is on. Example: array('modOtherModule' => array('always'=>'text')) or array('always' => array('FR'=>'textfr','MX'=>'textmx'...))
//$this->automatic_activation = array('FR'=>'MyModuleWasAutomaticallyActivatedBecauseOfYourCountryChoice');
//$this->always_enabled = false; // If true, can't be disabled. Value true is reserved for core modules. Not allowed for external modules.