dolibarr  16.0.5
index.php
Go to the documentation of this file.
1 <?php
2 /* Copyright (C) 2013-2014 Olivier Geffroy <jeff@jeffinfo.com>
3  * Copyright (C) 2013-2014 Florian Henry <florian.henry@open-concept.pro>
4  * Copyright (C) 2013-2021 Alexandre Spangaro <aspangaro@open-dsi.fr>
5  * Copyright (C) 2014-2015 Ari Elbaz (elarifr) <github@accedinfo.com>
6  * Copyright (C) 2014 Marcos García <marcosgdf@gmail.com>
7  * Copyright (C) 2014 Juanjo Menent <jmenent@2byte.es>
8  * Copyright (C) 2015 Jean-François Ferry <jfefe@aternatik.fr>
9  * Copyright (C) 2017 Laurent Destailleur <eldy@destailleur.fr>
10  * Copyright (C) 2021 Ferran Marcet <fmarcet@2byte.es>
11  *
12  * This program is free software; you can redistribute it and/or modify
13  * it under the terms of the GNU General Public License as published by
14  * the Free Software Foundation; either version 3 of the License, or
15  * (at your option) any later version.
16  *
17  * This program is distributed in the hope that it will be useful,
18  * but WITHOUT ANY WARRANTY; without even the implied warranty of
19  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20  * GNU General Public License for more details.
21  *
22  * You should have received a copy of the GNU General Public License
23  * along with this program. If not, see <https://www.gnu.org/licenses/>.
24  */
25 
32 require '../../main.inc.php';
33 require_once DOL_DOCUMENT_ROOT.'/core/lib/admin.lib.php';
34 require_once DOL_DOCUMENT_ROOT.'/core/lib/accounting.lib.php';
35 require_once DOL_DOCUMENT_ROOT.'/core/lib/date.lib.php';
36 
37 // Load translation files required by the page
38 $langs->loadLangs(array("compta", "bills", "admin", "accountancy", "other"));
39 
40 // Security access
41 if (empty($user->rights->accounting->chartofaccount)) {
43 }
44 
45 $action = GETPOST('action', 'aZ09');
46 
47 // Parameters ACCOUNTING_* and others
48 $list = array(
49  'ACCOUNTING_LENGTH_GACCOUNT',
50  'ACCOUNTING_LENGTH_AACCOUNT',
51 // 'ACCOUNTING_LIMIT_LIST_VENTILATION' // there is already a global parameter to define the nb of records in lists, we must use it in priority. Having one parameter for nb of record for each page is deprecated.
52 // 'ACCOUNTING_LENGTH_DESCRIPTION', // adjust size displayed for lines description for dol_trunc
53 // 'ACCOUNTING_LENGTH_DESCRIPTION_ACCOUNT', // adjust size displayed for select account description for dol_trunc
54 );
55 
56 $list_binding = array(
57  'ACCOUNTING_DATE_START_BINDING',
58  'ACCOUNTING_DEFAULT_PERIOD_ON_TRANSFER'
59 );
60 
61 $error = 0;
62 
63 
64 /*
65  * Actions
66  */
67 
68 if (in_array($action, array(
69  'setBANK_DISABLE_DIRECT_INPUT',
70  'setACCOUNTANCY_COMBO_FOR_AUX',
71  'setACCOUNTING_MANAGE_ZERO',
72  'setACCOUNTING_LIST_SORT_VENTILATION_TODO',
73  'setACCOUNTING_LIST_SORT_VENTILATION_DONE'))) {
74  $constname = preg_replace('/^set/', '', $action);
75  $constvalue = GETPOST('value', 'int');
76  $res = dolibarr_set_const($db, $constname, $constvalue, 'yesno', 0, '', $conf->entity);
77  if (!($res > 0)) {
78  $error++;
79  }
80 
81  if (!$error) {
82  setEventMessages($langs->trans("SetupSaved"), null, 'mesgs');
83  } else {
84  setEventMessages($langs->trans("Error"), null, 'mesgs');
85  }
86 }
87 
88 if ($action == 'update') {
89  $error = 0;
90 
91  if (!$error) {
92  foreach ($list as $constname) {
93  $constvalue = GETPOST($constname, 'alpha');
94  if (!dolibarr_set_const($db, $constname, $constvalue, 'chaine', 0, '', $conf->entity)) {
95  $error++;
96  }
97  }
98  if ($error) {
99  setEventMessages($langs->trans("Error"), null, 'errors');
100  }
101 
102  foreach ($list_binding as $constname) {
103  $constvalue = GETPOST($constname, 'alpha');
104 
105  if ($constname == 'ACCOUNTING_DATE_START_BINDING') {
106  $constvalue = dol_mktime(0, 0, 0, GETPOST($constname.'month', 'int'), GETPOST($constname.'day', 'int'), GETPOST($constname.'year', 'int'));
107  }
108 
109  if (!dolibarr_set_const($db, $constname, $constvalue, 'chaine', 0, '', $conf->entity)) {
110  $error++;
111  }
112  }
113  if ($error) {
114  setEventMessages($langs->trans("Error"), null, 'errors');
115  }
116  }
117 
118  if (!$error) {
119  setEventMessages($langs->trans("SetupSaved"), null, 'mesgs');
120  }
121 }
122 
123 if ($action == 'setlistsorttodo') {
124  $setlistsorttodo = GETPOST('value', 'int');
125  $res = dolibarr_set_const($db, "ACCOUNTING_LIST_SORT_VENTILATION_TODO", $setlistsorttodo, 'yesno', 0, '', $conf->entity);
126  if (!($res > 0)) {
127  $error++;
128  }
129 
130  if (!$error) {
131  setEventMessages($langs->trans("SetupSaved"), null, 'mesgs');
132  } else {
133  setEventMessages($langs->trans("Error"), null, 'mesgs');
134  }
135 }
136 
137 if ($action == 'setlistsortdone') {
138  $setlistsortdone = GETPOST('value', 'int');
139  $res = dolibarr_set_const($db, "ACCOUNTING_LIST_SORT_VENTILATION_DONE", $setlistsortdone, 'yesno', 0, '', $conf->entity);
140  if (!($res > 0)) {
141  $error++;
142  }
143 
144  if (!$error) {
145  setEventMessages($langs->trans("SetupSaved"), null, 'mesgs');
146  } else {
147  setEventMessages($langs->trans("Error"), null, 'mesgs');
148  }
149 }
150 
151 if ($action == 'setmanagezero') {
152  $setmanagezero = GETPOST('value', 'int');
153  $res = dolibarr_set_const($db, "ACCOUNTING_MANAGE_ZERO", $setmanagezero, 'yesno', 0, '', $conf->entity);
154  if (!($res > 0)) {
155  $error++;
156  }
157 
158  if (!$error) {
159  setEventMessages($langs->trans("SetupSaved"), null, 'mesgs');
160  } else {
161  setEventMessages($langs->trans("Error"), null, 'mesgs');
162  }
163 }
164 
165 if ($action == 'setdisabledirectinput') {
166  $setdisabledirectinput = GETPOST('value', 'int');
167  $res = dolibarr_set_const($db, "BANK_DISABLE_DIRECT_INPUT", $setdisabledirectinput, 'yesno', 0, '', $conf->entity);
168  if (!($res > 0)) {
169  $error++;
170  }
171 
172  if (!$error) {
173  setEventMessages($langs->trans("SetupSaved"), null, 'mesgs');
174  } else {
175  setEventMessages($langs->trans("Error"), null, 'mesgs');
176  }
177 }
178 
179 if ($action == 'setenabledraftexport') {
180  $setenabledraftexport = GETPOST('value', 'int');
181  $res = dolibarr_set_const($db, "ACCOUNTING_ENABLE_EXPORT_DRAFT_JOURNAL", $setenabledraftexport, 'yesno', 0, '', $conf->entity);
182  if (!($res > 0)) {
183  $error++;
184  }
185 
186  if (!$error) {
187  setEventMessages($langs->trans("SetupSaved"), null, 'mesgs');
188  } else {
189  setEventMessages($langs->trans("Error"), null, 'mesgs');
190  }
191 }
192 
193 if ($action == 'setenablesubsidiarylist') {
194  $setenablesubsidiarylist = GETPOST('value', 'int');
195  $res = dolibarr_set_const($db, "ACCOUNTANCY_COMBO_FOR_AUX", $setenablesubsidiarylist, 'yesno', 0, '', $conf->entity);
196  if (!($res > 0)) {
197  $error++;
198  }
199 
200  if (!$error) {
201  setEventMessages($langs->trans("SetupSaved"), null, 'mesgs');
202  } else {
203  setEventMessages($langs->trans("Error"), null, 'mesgs');
204  }
205 }
206 
207 if ($action == 'setdisablebindingonsales') {
208  $setdisablebindingonsales = GETPOST('value', 'int');
209  $res = dolibarr_set_const($db, "ACCOUNTING_DISABLE_BINDING_ON_SALES", $setdisablebindingonsales, 'yesno', 0, '', $conf->entity);
210  if (!($res > 0)) {
211  $error++;
212  }
213 
214  if (!$error) {
215  setEventMessages($langs->trans("SetupSaved"), null, 'mesgs');
216  } else {
217  setEventMessages($langs->trans("Error"), null, 'mesgs');
218  }
219 }
220 
221 if ($action == 'setdisablebindingonpurchases') {
222  $setdisablebindingonpurchases = GETPOST('value', 'int');
223  $res = dolibarr_set_const($db, "ACCOUNTING_DISABLE_BINDING_ON_PURCHASES", $setdisablebindingonpurchases, 'yesno', 0, '', $conf->entity);
224  if (!($res > 0)) {
225  $error++;
226  }
227 
228  if (!$error) {
229  setEventMessages($langs->trans("SetupSaved"), null, 'mesgs');
230  } else {
231  setEventMessages($langs->trans("Error"), null, 'mesgs');
232  }
233 }
234 
235 if ($action == 'setdisablebindingonexpensereports') {
236  $setdisablebindingonexpensereports = GETPOST('value', 'int');
237  $res = dolibarr_set_const($db, "ACCOUNTING_DISABLE_BINDING_ON_EXPENSEREPORTS", $setdisablebindingonexpensereports, 'yesno', 0, '', $conf->entity);
238  if (!($res > 0)) {
239  $error++;
240  }
241 
242  if (!$error) {
243  setEventMessages($langs->trans("SetupSaved"), null, 'mesgs');
244  } else {
245  setEventMessages($langs->trans("Error"), null, 'mesgs');
246  }
247 }
248 
249 
250 /*
251  * View
252  */
253 
254 $form = new Form($db);
255 
256 $title = $langs->trans('ConfigAccountingExpert');
257 llxHeader('', $title);
258 
259 $linkback = '';
260 //$linkback = '<a href="' . DOL_URL_ROOT . '/admin/modules.php?restore_lastsearch_values=1">' . $langs->trans("BackToModuleList") . '</a>';
261 print load_fiche_titre($title, $linkback, 'accountancy');
262 
263 // Show message if accountancy hidden options are activated to help to resolve some problems
264 if (!$user->admin) {
265  if (!empty($conf->global->FACTURE_DEPOSITS_ARE_JUST_PAYMENTS)) {
266  print '<div class="info">' . $langs->trans("ConstantIsOn", "FACTURE_DEPOSITS_ARE_JUST_PAYMENTS") . '</div>';
267  }
268  if (!empty($conf->global->FACTURE_SUPPLIER_DEPOSITS_ARE_JUST_PAYMENTS)) {
269  print '<div class="info">' . $langs->trans("ConstantIsOn", "FACTURE_SUPPLIER_DEPOSITS_ARE_JUST_PAYMENTS") . '</div>';
270  }
271  if (!empty($conf->global->ACCOUNTANCY_USE_PRODUCT_ACCOUNT_ON_THIRDPARTY)) {
272  print '<div class="info">' . $langs->trans("ConstantIsOn", "ACCOUNTANCY_USE_PRODUCT_ACCOUNT_ON_THIRDPARTY") . '</div>';
273  }
274  if (!empty($conf->global->MAIN_COMPANY_PERENTITY_SHARED)) {
275  print '<div class="info">' . $langs->trans("ConstantIsOn", "MAIN_COMPANY_PERENTITY_SHARED") . '</div>';
276  }
277  if (!empty($conf->global->MAIN_PRODUCT_PERENTITY_SHARED)) {
278  print '<div class="info">' . $langs->trans("ConstantIsOn", "MAIN_PRODUCT_PERENTITY_SHARED") . '</div>';
279  }
280 }
281 
282 print '<form action="'.$_SERVER["PHP_SELF"].'" method="post">';
283 print '<input type="hidden" name="token" value="'.newToken().'">';
284 print '<input type="hidden" name="action" value="update">';
285 
286 // Params
287 print '<table class="noborder centpercent">';
288 print '<tr class="liste_titre">';
289 print '<td colspan="2">'.$langs->trans('Options').'</td>';
290 print "</tr>\n";
291 
292 // TO DO Mutualize code for yes/no constants
293 
294 /* Set this option as a hidden option but keep it for some needs.
295 print '<tr>';
296 print '<td>'.$langs->trans("ACCOUNTING_ENABLE_EXPORT_DRAFT_JOURNAL").'</td>';
297 if (!empty($conf->global->ACCOUNTING_ENABLE_EXPORT_DRAFT_JOURNAL)) {
298  print '<td class="right"><a class="reposition" href="'.$_SERVER['PHP_SELF'].'?token='.newToken().'&enabledraftexport&value=0">';
299  print img_picto($langs->trans("Activated"), 'switch_on');
300  print '</a></td>';
301 } else {
302  print '<td class="right"><a class="reposition" href="'.$_SERVER['PHP_SELF'].'?token='.newToken().'&enabledraftexport&value=1">';
303  print img_picto($langs->trans("Disabled"), 'switch_off');
304  print '</a></td>';
305 }
306 print '</tr>';
307 */
308 
309 print '<tr class="oddeven">';
310 print '<td>'.$langs->trans("BANK_DISABLE_DIRECT_INPUT").'</td>';
311 if (!empty($conf->global->BANK_DISABLE_DIRECT_INPUT)) {
312  print '<td class="right"><a class="reposition" href="'.$_SERVER['PHP_SELF'].'?token='.newToken().'&action=setBANK_DISABLE_DIRECT_INPUT&value=0">';
313  print img_picto($langs->trans("Activated"), 'switch_on');
314  print '</a></td>';
315 } else {
316  print '<td class="right"><a class="reposition" href="'.$_SERVER['PHP_SELF'].'?token='.newToken().'&action=setBANK_DISABLE_DIRECT_INPUT&value=1">';
317  print img_picto($langs->trans("Disabled"), 'switch_off');
318  print '</a></td>';
319 }
320 print '</tr>';
321 
322 print '<tr class="oddeven">';
323 print '<td>'.$langs->trans("ACCOUNTANCY_COMBO_FOR_AUX");
324 print ' - <span class="opacitymedium">'.$langs->trans("NotRecommended").'</span>';
325 print '</td>';
326 
327 if (!empty($conf->global->ACCOUNTANCY_COMBO_FOR_AUX)) {
328  print '<td class="right"><a class="reposition" href="'.$_SERVER['PHP_SELF'].'?token='.newToken().'&action=setACCOUNTANCY_COMBO_FOR_AUX&value=0">';
329  print img_picto($langs->trans("Activated"), 'switch_on');
330  print '</a></td>';
331 } else {
332  print '<td class="right"><a class="reposition" href="'.$_SERVER['PHP_SELF'].'?token='.newToken().'&action=setACCOUNTANCY_COMBO_FOR_AUX&value=1">';
333  print img_picto($langs->trans("Disabled"), 'switch_off');
334  print '</a></td>';
335 }
336 print '</tr>';
337 
338 print '<tr class="oddeven">';
339 print '<td>'.$langs->trans("ACCOUNTING_MANAGE_ZERO").'</td>';
340 if (!empty($conf->global->ACCOUNTING_MANAGE_ZERO)) {
341  print '<td class="right"><a class="reposition" href="'.$_SERVER['PHP_SELF'].'?token='.newToken().'&action=setACCOUNTING_MANAGE_ZERO&value=0">';
342  print img_picto($langs->trans("Activated"), 'switch_on');
343  print '</a></td>';
344 } else {
345  print '<td class="right"><a class="reposition" href="'.$_SERVER['PHP_SELF'].'?token='.newToken().'&action=setACCOUNTING_MANAGE_ZERO&value=1">';
346  print img_picto($langs->trans("Disabled"), 'switch_off');
347  print '</a></td>';
348 }
349 print '</tr>';
350 
351 // Param a user $user->rights->accounting->chartofaccount can access
352 foreach ($list as $key) {
353  print '<tr class="oddeven value">';
354 
355  if (!empty($conf->global->ACCOUNTING_MANAGE_ZERO) && ($key == 'ACCOUNTING_LENGTH_GACCOUNT' || $key == 'ACCOUNTING_LENGTH_AACCOUNT')) {
356  continue;
357  }
358 
359  // Param
360  $label = $langs->trans($key);
361  print '<td>'.$label.'</td>';
362  // Value
363  print '<td class="right">';
364  print '<input type="text" class="maxwidth50 right" id="'.$key.'" name="'.$key.'" value="'.getDolGlobalString($key).'">';
365 
366  print '</td>';
367  print '</tr>';
368 }
369 print '</table>';
370 print '<br>';
371 
372 // Binding params
373 print '<table class="noborder centpercent">';
374 print '<tr class="liste_titre">';
375 print '<td colspan="2">'.$langs->trans('BindingOptions').'</td>';
376 print "</tr>\n";
377 
378 // TO DO Mutualize code for yes/no constants
379 print '<tr class="oddeven">';
380 print '<td>'.$langs->trans("ACCOUNTING_LIST_SORT_VENTILATION_TODO").'</td>';
381 if (!empty($conf->global->ACCOUNTING_LIST_SORT_VENTILATION_TODO)) {
382  print '<td class="right"><a class="reposition" href="'.$_SERVER['PHP_SELF'].'?token='.newToken().'&action=setACCOUNTING_LIST_SORT_VENTILATION_TODO&value=0">';
383  print img_picto($langs->trans("Activated"), 'switch_on');
384  print '</a></td>';
385 } else {
386  print '<td class="right"><a class="reposition" href="'.$_SERVER['PHP_SELF'].'?token='.newToken().'&action=setACCOUNTING_LIST_SORT_VENTILATION_TODO&value=1">';
387  print img_picto($langs->trans("Disabled"), 'switch_off');
388  print '</a></td>';
389 }
390 print '</tr>';
391 
392 print '<tr class="oddeven">';
393 print '<td>'.$langs->trans("ACCOUNTING_LIST_SORT_VENTILATION_DONE").'</td>';
394 if (!empty($conf->global->ACCOUNTING_LIST_SORT_VENTILATION_DONE)) {
395  print '<td class="right"><a class="reposition" href="'.$_SERVER['PHP_SELF'].'?token='.newToken().'&action=setACCOUNTING_LIST_SORT_VENTILATION_DONE&value=0">';
396  print img_picto($langs->trans("Activated"), 'switch_on');
397  print '</a></td>';
398 } else {
399  print '<td class="right"><a class="reposition" href="'.$_SERVER['PHP_SELF'].'?token='.newToken().'&action=setACCOUNTING_LIST_SORT_VENTILATION_DONE&value=1">';
400  print img_picto($langs->trans("Disabled"), 'switch_off');
401  print '</a></td>';
402 }
403 print '</tr>';
404 
405 // Param a user $user->rights->accounting->chartofaccount can access
406 foreach ($list_binding as $key) {
407  print '<tr class="oddeven value">';
408 
409  // Param
410  $label = $langs->trans($key);
411  print '<td>'.$label.'</td>';
412  // Value
413  print '<td class="right">';
414  if ($key == 'ACCOUNTING_DATE_START_BINDING') {
415  print $form->selectDate((!empty($conf->global->$key) ? $db->idate($conf->global->$key) : -1), $key, 0, 0, 1);
416  } elseif ($key == 'ACCOUNTING_DEFAULT_PERIOD_ON_TRANSFER') {
417  $array = array(0=>$langs->trans("PreviousMonth"), 1=>$langs->trans("CurrentMonth"), 2=>$langs->trans("Fiscalyear"));
418  print $form->selectarray($key, $array, (isset($conf->global->ACCOUNTING_DEFAULT_PERIOD_ON_TRANSFER) ? $conf->global->ACCOUNTING_DEFAULT_PERIOD_ON_TRANSFER : 0));
419  } else {
420  print '<input type="text" class="maxwidth100" id="'.$key.'" name="'.$key.'" value="'.getDolGlobalString($key).'">';
421  }
422 
423  print '</td>';
424  print '</tr>';
425 }
426 
427 print '<tr class="oddeven">';
428 print '<td>'.$langs->trans("ACCOUNTING_DISABLE_BINDING_ON_SALES").'</td>';
429 if (!empty($conf->global->ACCOUNTING_DISABLE_BINDING_ON_SALES)) {
430  print '<td class="right"><a class="reposition" href="'.$_SERVER['PHP_SELF'].'?token='.newToken().'&action=setdisablebindingonsales&value=0">';
431  print img_picto($langs->trans("Activated"), 'switch_on', '', false, 0, 0, '', 'warning');
432  print '</a></td>';
433 } else {
434  print '<td class="right"><a class="reposition" href="'.$_SERVER['PHP_SELF'].'?token='.newToken().'&action=setdisablebindingonsales&value=1">';
435  print img_picto($langs->trans("Disabled"), 'switch_off');
436  print '</a></td>';
437 }
438 print '</tr>';
439 
440 print '<tr class="oddeven">';
441 print '<td>'.$langs->trans("ACCOUNTING_DISABLE_BINDING_ON_PURCHASES").'</td>';
442 if (!empty($conf->global->ACCOUNTING_DISABLE_BINDING_ON_PURCHASES)) {
443  print '<td class="right"><a class="reposition" href="'.$_SERVER['PHP_SELF'].'?token='.newToken().'&action=setdisablebindingonpurchases&value=0">';
444  print img_picto($langs->trans("Activated"), 'switch_on', '', false, 0, 0, '', 'warning');
445  print '</a></td>';
446 } else {
447  print '<td class="right"><a class="reposition" href="'.$_SERVER['PHP_SELF'].'?token='.newToken().'&action=setdisablebindingonpurchases&value=1">';
448  print img_picto($langs->trans("Disabled"), 'switch_off');
449  print '</a></td>';
450 }
451 print '</tr>';
452 
453 print '<tr class="oddeven">';
454 print '<td>'.$langs->trans("ACCOUNTING_DISABLE_BINDING_ON_EXPENSEREPORTS").'</td>';
455 if (!empty($conf->global->ACCOUNTING_DISABLE_BINDING_ON_EXPENSEREPORTS)) {
456  print '<td class="right"><a class="reposition" href="'.$_SERVER['PHP_SELF'].'?token='.newToken().'&action=setdisablebindingonexpensereports&value=0">';
457  print img_picto($langs->trans("Activated"), 'switch_on', '', false, 0, 0, '', 'warning');
458  print '</a></td>';
459 } else {
460  print '<td class="right"><a class="reposition" href="'.$_SERVER['PHP_SELF'].'?token='.newToken().'&action=setdisablebindingonexpensereports&value=1">';
461  print img_picto($langs->trans("Disabled"), 'switch_off');
462  print '</a></td>';
463 }
464 print '</tr>';
465 
466 print '</table>';
467 
468 print '<div class="center"><input type="submit" class="button button-edit" name="button" value="'.$langs->trans('Modify').'"></div>';
469 
470 print '</form>';
471 
472 // End of page
473 llxFooter();
474 $db->close();
load_fiche_titre
load_fiche_titre($titre, $morehtmlright='', $picto='generic', $pictoisfullpath=0, $id='', $morecssontable='', $morehtmlcenter='')
Load a title with picto.
Definition: functions.lib.php:5204
GETPOST
GETPOST($paramname, $check='alphanohtml', $method=0, $filter=null, $options=null, $noreplace=0)
Return value of a param into GET or POST supervariable.
Definition: functions.lib.php:484
$form
if($cancel &&! $id) if($action=='add' &&! $cancel) if($action=='delete') if($id) $form
Actions.
Definition: card.php:142
img_picto
img_picto($titlealt, $picto, $moreatt='', $pictoisfullpath=false, $srconly=0, $notitle=0, $alt='', $morecss='', $marginleftonlyshort=2)
Show picto whatever it's its name (generic function)
Definition: functions.lib.php:3880
llxFooter
llxFooter()
Footer empty.
Definition: index.php:71
llxHeader
if(!defined('NOTOKENRENEWAL')) if(!defined('NOLOGIN')) if(!defined('NOCSRFCHECK')) if(!defined('NOREQUIREMENU')) if(!defined('NOREQUIREHTML')) if(!defined('NOREQUIREAJAX')) if(!defined('NOIPCHECK')) if(!defined('NOBROWSERNOTIF')) llxHeader()
Header empty.
Definition: index.php:63
getDolGlobalString
if(!function_exists('utf8_encode')) if(!function_exists('utf8_decode')) getDolGlobalString($key, $default='')
Return dolibarr global constant string value.
Definition: functions.lib.php:80
newToken
newToken()
Return the value of token currently saved into session with name 'newtoken'.
Definition: functions.lib.php:10878
dolibarr_set_const
dolibarr_set_const($db, $name, $value, $type='chaine', $visible=0, $note='', $entity=1)
Insert a parameter (key,value) into database (delete old key then insert it again).
Definition: admin.lib.php:627
Form
Class to manage generation of HTML components Only common components must be here.
Definition: html.form.class.php:52
setEventMessages
setEventMessages($mesg, $mesgs, $style='mesgs', $messagekey='')
Set event messages in dol_events session object.
Definition: functions.lib.php:8137
accessforbidden
accessforbidden($message='', $printheader=1, $printfooter=1, $showonlymessage=0, $params=null)
Show a message to say access is forbidden and stop program Calling this function terminate execution ...
Definition: security.lib.php:933
dol_mktime
dol_mktime($hour, $minute, $second, $month, $day, $year, $gm='auto', $check=1)
Return a timestamp date built from detailed informations (by default a local PHP server timestamp) Re...
Definition: functions.lib.php:2757