dolibarr
25.0.0-alpha
Main Page
Related Pages
Topics
Classes
Files
Examples
File List
File Members
dolibarr_dev
htdocs
core
modules
modDocumentGeneration.class.php
Go to the documentation of this file.
1
<?php
2
/* Copyright (C) 2007 Rodolphe Quiedeville <rodolphe@quiedeville.org>
3
* Copyright (C) 2005-2009 Regis Houssin <regis.houssin@inodbox.com>
4
*
5
* This program is free software; you can redistribute it and/or modify
6
* it under the terms of the GNU General Public License as published by
7
* the Free Software Foundation; either version 3 of the License, or
8
* (at your option) any later version.
9
*
10
* This program is distributed in the hope that it will be useful,
11
* but WITHOUT ANY WARRANTY; without even the implied warranty of
12
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13
* GNU General Public License for more details.
14
*
15
* You should have received a copy of the GNU General Public License
16
* along with this program. If not, see <https://www.gnu.org/licenses/>.
17
* or see https://www.gnu.org/
18
*/
19
28
include_once DOL_DOCUMENT_ROOT.
'/core/modules/DolibarrModules.class.php'
;
29
30
34
class
modDocumentGeneration
extends
DolibarrModules
35
{
41
public
function
__construct
($db)
42
{
43
$this->db = $db;
44
$this->numero = 1520;
45
46
$this->family =
"technic"
;
47
$this->module_position =
'78'
;
48
// Module label (no space allowed), used if translation string 'ModuleXXXName' not found (where XXX is value of numeric property 'numero' of module)
49
$this->
name
= preg_replace(
'/^mod/i'
,
''
, get_class($this));
50
$this->
description
=
"Direct mail document generation"
;
51
// Possible values for version are: 'development', 'experimental', 'dolibarr' or version
52
$this->
version
=
'development'
;
53
54
$this->const_name =
'MAIN_MODULE_'
.strtoupper($this->
name
);
55
$this->picto =
'email'
;
56
57
// Data directories to create when module is enabled
58
$this->dirs = array(
"/documentgeneration/temp"
);
59
60
// Config pages
61
//$this->config_page_url = array("document.php");
62
63
// Dependencies
64
$this->depends = array();
65
$this->requiredby = array();
66
$this->conflictwith = array();
67
$this->langfiles = array(
"orders"
,
"bills"
,
"companies"
,
"mails"
);
68
69
// Constants
70
71
$this->
const
= array();
72
73
// Boxes
74
$this->boxes = array();
75
76
// Permissions
77
$this->rights = array();
78
$this->rights_class =
'document'
;
79
80
$r = 0;
81
82
$this->rights[$r][0] = 1521;
83
$this->rights[$r][1] =
'Lire les documents'
;
84
$this->rights[$r][2] =
'r'
;
85
$this->rights[$r][3] = 0;
86
$this->rights[$r][4] =
'lire'
;
87
88
$r++;
89
$this->rights[$r][0] = 1522;
90
$this->rights[$r][1] =
'Supprimer les documents clients'
;
91
$this->rights[$r][2] =
'd'
;
92
$this->rights[$r][3] = 0;
93
$this->rights[$r][4] =
'supprimer'
;
94
}
95
96
105
public
function
init
($options =
''
)
106
{
107
global
$conf
;
108
109
// Permissions
110
$this->
remove
($options);
111
112
$sql = array();
113
114
return
$this->
_init
($sql, $options);
115
}
116
}
$conf
if(!isModEnabled('ai')||!getDolGlobalString('AI_ASSISTANT_ENABLED')) global $conf
The main.inc.php has been included so the following variable are now defined:
Definition
chat_history.php:55
DolibarrModules
Class DolibarrModules.
Definition
DolibarrModules.class.php:40
DolibarrModules\_init
_init($array_sql, $options='')
Enables a module.
Definition
DolibarrModules.class.php:568
modDocumentGeneration
Class to describe and enable module Document.
Definition
modDocumentGeneration.class.php:35
modDocumentGeneration\init
init($options='')
Function called when module is enabled.
Definition
modDocumentGeneration.class.php:105
modDocumentGeneration\__construct
__construct($db)
Constructor.
Definition
modDocumentGeneration.class.php:41
description
print $script_file $mode $langs defaultlang(is_numeric($duration_value) ? " delay=". $duration_value :"").(is_numeric($duration_value2) ? " after cd cd cd description as description
Only used if Module[ID]Desc translation string is not found.
Definition
email_expire_services_to_customers.php:96
version
$conf browser version
Definition
main.inc.php:229
name
$conf db name
Only used if Module[ID]Name translation string is not found.
Definition
repair.php:165
Generated on Sun Nov 1 2026 01:00:21 for
dolibarr
by Doxygen 1.11.0