dolibarr 21.0.0-alpha
modImport.class.php
Go to the documentation of this file.
1<?php
2/* Copyright (C) 2005-2009 Laurent Destailleur <eldy@users.sourceforge.net>
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 */
18
27include_once DOL_DOCUMENT_ROOT.'/core/modules/DolibarrModules.class.php';
28
29
34{
40 public function __construct($db)
41 {
42 $this->db = $db;
43 $this->numero = 250;
44
45 $this->family = "technic";
46 $this->module_position = '70';
47 // Module label (no space allowed), used if translation string 'ModuleXXXName' not found (where XXX is value of numeric property 'numero' of module)
48 $this->name = preg_replace('/^mod/i', '', get_class($this));
49 $this->description = "Outils d'imports de donnees Dolibarr (via un assistant)";
50 // Possible values for version are: 'development', 'experimental', 'dolibarr' or 'dolibarr_deprecated' or version
51 $this->version = 'dolibarr';
52 $this->const_name = 'MAIN_MODULE_'.strtoupper($this->name);
53 $this->picto = 'technic';
54
55 // Data directories to create when module is enabled
56 $this->dirs = array("/import/temp");
57
58 // Config pages
59 $this->config_page_url = array("import.php");
60
61 // Dependencies
62 $this->hidden = false; // A condition to hide module
63 $this->depends = array(); // List of module class names as string that must be enabled if this module is enabled
64 $this->requiredby = array(); // List of module ids to disable if this one is disabled
65 $this->conflictwith = array(); // List of module class names as string this module is in conflict with
66 $this->phpmin = array(7, 0); // Minimum version of PHP required by module - Need auto_detect_line_endings php option to solve MAC pbs.
67 $this->phpmax = array();
68 $this->need_dolibarr_version = array(2, 7, -1); // Minimum version of Dolibarr required by module
69 $this->enabled_bydefault = true; // Will be enabled during install
70
71 // Constants
72 $this->const = array();
73
74 // Boxes
75 $this->boxes = array();
76
77 // Permissions
78 $this->rights = array();
79 $this->rights_class = 'import';
80 $r = 0;
81
82 $r++;
83 $this->rights[$r][0] = 1251;
84 $this->rights[$r][1] = 'Run mass imports of external data (data load)';
85 $this->rights[$r][2] = 'r';
86 $this->rights[$r][3] = 0;
87 $this->rights[$r][4] = 'run';
88
89
90 // Menus
91 //-------
92 $this->menu = 1; // This module add menu entries. They are coded into menu manager.
93 }
94}
Class DolibarrModules.
Class to describe and enable module Import.
__construct($db)
Constructor.
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.
$conf db name
Only used if Module[ID]Name translation string is not found.
Definition repair.php:142