28 include_once DOL_DOCUMENT_ROOT.
'/core/modules/DolibarrModules.class.php';
47 $this->numero = 68305;
50 $this->rights_class =
'webhook';
54 $this->family =
"interface";
57 $this->module_position =
'90';
62 $this->
name = preg_replace(
'/^mod/i',
'', get_class($this));
67 $this->descriptionlong =
"WebhookDescription";
70 $this->version =
'dolibarr';
75 $this->const_name =
'MAIN_MODULE_'.strtoupper($this->
name);
81 $this->picto =
'webhook';
84 $this->module_parts = array(
120 'moduleforexternal' => 0,
125 $this->dirs = array(
"/webhook/temp");
128 $this->config_page_url = array(
"webhook.php");
132 $this->hidden =
false;
134 $this->depends = array();
135 $this->requiredby = array();
136 $this->conflictwith = array();
139 $this->langfiles = array();
142 $this->phpmin = array(7, 0);
143 $this->need_dolibarr_version = array(11, -3);
146 $this->warnings_activation = array();
147 $this->warnings_activation_ext = array();
156 $this->
const = array();
164 if (!isset($conf->webhook) || !isset($conf->webhook->enabled)) {
165 $conf->webhook =
new stdClass();
166 $conf->webhook->enabled = 0;
170 $this->tabs = array();
198 $this->dictionaries = array();
225 $this->boxes = array(
236 $this->cronjobs = array(
258 $this->rights = array();
262 $this->rights[$r][0] = $this->numero . sprintf(
"%02d", $r + 1);
263 $this->rights[$r][1] =
'Read Webhooks';
264 $this->rights[$r][4] =
'webhook_target';
265 $this->rights[$r][5] =
'read';
267 $this->rights[$r][0] = $this->numero . sprintf(
"%02d", $r + 1);
268 $this->rights[$r][1] =
'Create/Update Webhooks';
269 $this->rights[$r][4] =
'webhook_target';
270 $this->rights[$r][5] =
'write';
272 $this->rights[$r][0] = $this->numero . sprintf(
"%02d", $r + 1);
273 $this->rights[$r][1] =
'Delete Webhooks';
274 $this->rights[$r][4] =
'webhook_target';
275 $this->rights[$r][5] =
'delete';
280 $this->menu = array();
461 public function init($options =
'')
463 global $conf, $langs;
465 $result = $this->
_load_tables(
'/install/mysql/tables/',
'webhook');
472 $this->
remove($options);
487 public function remove($options =
'')
_init($array_sql, $options='')
Enables a module.
_remove($array_sql, $options='')
Disable function.
_load_tables($reldir, $onlywithsuffix='')
Create tables and keys required by module:
Description and activation class for module Webhook.
__construct($db)
Constructor.
init($options='')
Function called when module is enabled.
if(isModEnabled('facture') && $user->hasRight('facture', 'lire')) if((isModEnabled('fournisseur') &&empty($conf->global->MAIN_USE_NEW_SUPPLIERMOD) && $user->hasRight("fournisseur", "facture", "lire"))||(isModEnabled('supplier_invoice') && $user->hasRight("supplier_invoice", "lire"))) if(isModEnabled('don') && $user->hasRight('don', 'lire')) if(isModEnabled('tax') &&!empty($user->rights->tax->charges->lire)) if(isModEnabled('facture') &&isModEnabled('commande') && $user->hasRight("commande", "lire") &&empty($conf->global->WORKFLOW_DISABLE_CREATE_INVOICE_FROM_ORDER)) $sql
Social contributions to pay.
print *****$script_file(".$version.") pid cd cd cd description as description
Only used if Module[ID]Desc translation string is not found.
$conf db name
Only used if Module[ID]Name translation string is not found.