dolibarr  13.0.2
setup_candidatures.php
Go to the documentation of this file.
1 <?php
2 /* Copyright (C) 2004-2017 Laurent Destailleur <eldy@users.sourceforge.net>
3  * Copyright (C) 2020 Adminson Alicealalalamdskfldmjgdfgdfhfghgfh <testldr9@dolicloud.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 
25 // Load Dolibarr environment
26 $res = 0;
27 // Try main.inc.php into web root known defined into CONTEXT_DOCUMENT_ROOT (not always defined)
28 if (!$res && !empty($_SERVER["CONTEXT_DOCUMENT_ROOT"])) $res = @include $_SERVER["CONTEXT_DOCUMENT_ROOT"]."/main.inc.php";
29 // Try main.inc.php into web root detected using web root calculated from SCRIPT_FILENAME
30 $tmp = empty($_SERVER['SCRIPT_FILENAME']) ? '' : $_SERVER['SCRIPT_FILENAME']; $tmp2 = realpath(__FILE__); $i = strlen($tmp) - 1; $j = strlen($tmp2) - 1;
31 while ($i > 0 && $j > 0 && isset($tmp[$i]) && isset($tmp2[$j]) && $tmp[$i] == $tmp2[$j]) { $i--; $j--; }
32 if (!$res && $i > 0 && file_exists(substr($tmp, 0, ($i + 1))."/main.inc.php")) $res = @include substr($tmp, 0, ($i + 1))."/main.inc.php";
33 if (!$res && $i > 0 && file_exists(dirname(substr($tmp, 0, ($i + 1)))."/main.inc.php")) $res = @include dirname(substr($tmp, 0, ($i + 1)))."/main.inc.php";
34 // Try main.inc.php using relative path
35 if (!$res && file_exists("../../main.inc.php")) $res = @include "../../main.inc.php";
36 if (!$res && file_exists("../../../main.inc.php")) $res = @include "../../../main.inc.php";
37 if (!$res) die("Include of main fails");
38 
39 global $langs, $user;
40 
41 // Libraries
42 require_once DOL_DOCUMENT_ROOT."/core/lib/admin.lib.php";
43 require_once DOL_DOCUMENT_ROOT.'/recruitment/lib/recruitment.lib.php';
44 require_once DOL_DOCUMENT_ROOT."/recruitment/class/recruitmentjobposition.class.php";
45 
46 // Translations
47 $langs->loadLangs(array("admin", "recruitment"));
48 
49 // Access control
50 if (!$user->admin) accessforbidden();
51 
52 // Parameters
53 $action = GETPOST('action', 'aZ09');
54 $backtopage = GETPOST('backtopage', 'alpha');
55 
56 $value = GETPOST('value', 'alpha');
57 $label = GETPOST('label', 'alpha');
58 $scandir = GETPOST('scan_dir', 'alpha');
59 $type = 'recruitmentcandidature';
60 
61 $arrayofparameters = array(
62 // 'RECRUITMENT_MYPARAM1'=>array('css'=>'minwidth200', 'enabled'=>1),
63 // 'RECRUITMENT_MYPARAM2'=>array('css'=>'minwidth500', 'enabled'=>1)
64 );
65 
66 $error = 0;
67 $setupnotempty = 0;
68 
69 
70 /*
71  * Actions
72  */
73 
74 if ((float) DOL_VERSION >= 6)
75 {
76  include DOL_DOCUMENT_ROOT.'/core/actions_setmoduleoptions.inc.php';
77 }
78 
79 if ($action == 'updateMask')
80 {
81  $maskconstorder = GETPOST('maskconstorder', 'alpha');
82  $maskorder = GETPOST('maskorder', 'alpha');
83 
84  if ($maskconstorder) $res = dolibarr_set_const($db, $maskconstorder, $maskorder, 'chaine', 0, '', $conf->entity);
85 
86  if (!($res > 0)) $error++;
87 
88  if (!$error)
89  {
90  setEventMessages($langs->trans("SetupSaved"), null, 'mesgs');
91  } else {
92  setEventMessages($langs->trans("Error"), null, 'errors');
93  }
94 } elseif ($action == 'specimen')
95 {
96  $modele = GETPOST('module', 'alpha');
97  $tmpobjectkey = GETPOST('object');
98 
99  $tmpobject = new $tmpobjectkey($db);
100  $tmpobject->initAsSpecimen();
101 
102  // Search template files
103  $file = ''; $classname = ''; $filefound = 0;
104  $dirmodels = array_merge(array('/'), (array) $conf->modules_parts['models']);
105  foreach ($dirmodels as $reldir)
106  {
107  $file = dol_buildpath($reldir."core/modules/mymodule/doc/pdf_".$modele."_".strtolower($tmpobjectkey).".modules.php", 0);
108  if (file_exists($file))
109  {
110  $filefound = 1;
111  $classname = "pdf_".$modele;
112  break;
113  }
114  }
115 
116  if ($filefound)
117  {
118  require_once $file;
119 
120  $module = new $classname($db);
121 
122  if ($module->write_file($tmpobject, $langs) > 0)
123  {
124  header("Location: ".DOL_URL_ROOT."/document.php?modulepart=".strtolower($tmpobjectkey)."&file=SPECIMEN.pdf");
125  return;
126  } else {
127  setEventMessages($module->error, null, 'errors');
128  dol_syslog($module->error, LOG_ERR);
129  }
130  } else {
131  setEventMessages($langs->trans("ErrorModuleNotFound"), null, 'errors');
132  dol_syslog($langs->trans("ErrorModuleNotFound"), LOG_ERR);
133  }
134 }
135 
136 // Activate a model
137 elseif ($action == 'set') {
138  $ret = addDocumentModel($value, $type, $label, $scandir);
139 } elseif ($action == 'del') {
140  $tmpobjectkey = GETPOST('object');
141 
142  $ret = delDocumentModel($value, $type);
143  if ($ret > 0) {
144  $constforval = 'RECRUITMENT_'.strtoupper($tmpobjectkey).'_ADDON_PDF';
145  if ($conf->global->$constforval == "$value") dolibarr_del_const($db, $constforval, $conf->entity);
146  }
147 }
148 
149 elseif ($action == 'setmod') {
150  // TODO Check if numbering module chosen can be activated by calling method canBeActivated
151  $tmpobjectkey = GETPOST('object');
152  if (!empty($tmpobjectkey)) {
153  $constforval = 'RECRUITMENT_'.strtoupper($tmpobjectkey)."_ADDON";
154 
155  dolibarr_set_const($db, $constforval, $value, 'chaine', 0, '', $conf->entity);
156  }
157 }
158 
159 // Set default model
160 elseif ($action == 'setdoc') {
161  $tmpobjectkey = GETPOST('object');
162  $constforval = 'RECRUITMENT_'.strtoupper($tmpobjectkey).'_ADDON_PDF';
163  if (dolibarr_set_const($db, $constforval, $value, 'chaine', 0, '', $conf->entity)) {
164  // The constant that was read before the new set
165  // We therefore requires a variable to have a coherent view
166  $conf->global->$constforval = $value;
167  }
168 
169  // We disable/enable the document template (into llx_document_model table)
170  $ret = delDocumentModel($value, $type);
171  if ($ret > 0) {
172  $ret = addDocumentModel($value, $type, $label, $scandir);
173  }
174 } elseif ($action == 'unsetdoc') {
175  $tmpobjectkey = GETPOST('object');
176  if (!empty($tmpobjectkey)) {
177  $constforval = 'RECRUITMENT_'.strtoupper($tmpobjectkey).'_ADDON_PDF';
178  dolibarr_del_const($db, $constforval, $conf->entity);
179  }
180 }
181 
182 
183 
184 /*
185  * View
186  */
187 
188 $form = new Form($db);
189 
190 $dirmodels = array_merge(array('/'), (array) $conf->modules_parts['models']);
191 
192 $page_name = "RecruitmentSetup";
193 llxHeader('', $langs->trans($page_name));
194 
195 // Subheader
196 $linkback = '<a href="'.($backtopage ? $backtopage : DOL_URL_ROOT.'/admin/modules.php?restore_lastsearch_values=1').'">'.$langs->trans("BackToModuleList").'</a>';
197 
198 print load_fiche_titre($langs->trans($page_name), $linkback, 'title_setup');
199 
200 // Configuration header
202 print dol_get_fiche_head($head, 'settings_candidatures', '', -1, '');
203 
204 // Setup page goes here
205 //echo '<span class="opacitymedium">'.$langs->trans("RecruitmentSetupPage").'</span><br><br>';
206 
207 
208 if ($action == 'edit')
209 {
210  print '<form method="POST" action="'.$_SERVER["PHP_SELF"].'">';
211  print '<input type="hidden" name="token" value="'.newToken().'">';
212  print '<input type="hidden" name="action" value="update">';
213 
214  print '<table class="noborder centpercent">';
215  print '<tr class="liste_titre"><td class="titlefield">'.$langs->trans("Parameter").'</td><td>'.$langs->trans("Value").'</td></tr>';
216 
217  foreach ($arrayofparameters as $key => $val)
218  {
219  print '<tr class="oddeven"><td>';
220  $tooltiphelp = (($langs->trans($key.'Tooltip') != $key.'Tooltip') ? $langs->trans($key.'Tooltip') : '');
221  print $form->textwithpicto($langs->trans($key), $tooltiphelp);
222  print '</td><td><input name="'.$key.'" class="flat '.(empty($val['css']) ? 'minwidth200' : $val['css']).'" value="'.$conf->global->$key.'"></td></tr>';
223  }
224  print '</table>';
225 
226  print '<br><div class="center">';
227  print '<input class="button button-save" type="submit" value="'.$langs->trans("Save").'">';
228  print '</div>';
229 
230  print '</form>';
231  print '<br>';
232 } else {
233  if (!empty($arrayofparameters))
234  {
235  print '<table class="noborder centpercent">';
236  print '<tr class="liste_titre"><td class="titlefield">'.$langs->trans("Parameter").'</td><td>'.$langs->trans("Value").'</td></tr>';
237 
238  foreach ($arrayofparameters as $key => $val)
239  {
240  $setupnotempty++;
241 
242  print '<tr class="oddeven"><td>';
243  $tooltiphelp = (($langs->trans($key.'Tooltip') != $key.'Tooltip') ? $langs->trans($key.'Tooltip') : '');
244  print $form->textwithpicto($langs->trans($key), $tooltiphelp);
245  print '</td><td>'.$conf->global->$key.'</td></tr>';
246  }
247 
248  print '</table>';
249 
250  print '<div class="tabsAction">';
251  print '<a class="butAction" href="'.$_SERVER["PHP_SELF"].'?action=edit">'.$langs->trans("Modify").'</a>';
252  print '</div>';
253  }
254 }
255 
256 
257 $moduledir = 'recruitment';
258 $myTmpObjects = array();
259 $myTmpObjects['RecruitmentCandidature'] = array('includerefgeneration'=>1, 'includedocgeneration'=>0);
260 
261 
262 foreach ($myTmpObjects as $myTmpObjectKey => $myTmpObjectArray) {
263  if ($myTmpObjectArray['includerefgeneration']) {
264  /*
265  * Orders Numbering model
266  */
267  $setupnotempty++;
268 
269  print load_fiche_titre($langs->trans("NumberingModules", $myTmpObjectKey), '', '');
270 
271  print '<table class="noborder centpercent">';
272  print '<tr class="liste_titre">';
273  print '<td>'.$langs->trans("Name").'</td>';
274  print '<td>'.$langs->trans("Description").'</td>';
275  print '<td class="nowrap">'.$langs->trans("Example").'</td>';
276  print '<td class="center" width="60">'.$langs->trans("Status").'</td>';
277  print '<td class="center" width="16">'.$langs->trans("ShortInfo").'</td>';
278  print '</tr>'."\n";
279 
280  clearstatcache();
281 
282  foreach ($dirmodels as $reldir)
283  {
284  $dir = dol_buildpath($reldir."core/modules/".$moduledir);
285 
286  if (is_dir($dir))
287  {
288  $handle = opendir($dir);
289  if (is_resource($handle))
290  {
291  while (($file = readdir($handle)) !== false)
292  {
293  if (strpos($file, 'mod_'.strtolower($myTmpObjectKey).'_') === 0 && substr($file, dol_strlen($file) - 3, 3) == 'php')
294  {
295  $file = substr($file, 0, dol_strlen($file) - 4);
296 
297  require_once $dir.'/'.$file.'.php';
298 
299  $module = new $file($db);
300 
301  // Show modules according to features level
302  if ($module->version == 'development' && $conf->global->MAIN_FEATURES_LEVEL < 2) continue;
303  if ($module->version == 'experimental' && $conf->global->MAIN_FEATURES_LEVEL < 1) continue;
304 
305  if ($module->isEnabled())
306  {
307  dol_include_once('/'.$moduledir.'/class/'.strtolower($myTmpObjectKey).'.class.php');
308 
309  print '<tr class="oddeven"><td>'.$module->name."</td><td>\n";
310  print $module->info();
311  print '</td>';
312 
313  // Show example of numbering model
314  print '<td class="nowrap">';
315  $tmp = $module->getExample();
316  if (preg_match('/^Error/', $tmp)) {
317  $langs->load("errors");
318  print '<div class="error">'.$langs->trans($tmp).'</div>';
319  } elseif ($tmp == 'NotConfigured') print $langs->trans($tmp);
320  else print $tmp;
321  print '</td>'."\n";
322 
323  print '<td class="center">';
324  $constforvar = 'RECRUITMENT_'.strtoupper($myTmpObjectKey).'_ADDON';
325  if ($conf->global->$constforvar == $file)
326  {
327  print img_picto($langs->trans("Activated"), 'switch_on');
328  } else {
329  print '<a href="'.$_SERVER["PHP_SELF"].'?action=setmod&token='.newToken().'&object='.strtolower($myTmpObjectKey).'&value='.urlencode($file).'">';
330  print img_picto($langs->trans("Disabled"), 'switch_off');
331  print '</a>';
332  }
333  print '</td>';
334 
335  $mytmpinstance = new $myTmpObjectKey($db);
336  $mytmpinstance->initAsSpecimen();
337 
338  // Info
339  $htmltooltip = '';
340  $htmltooltip .= ''.$langs->trans("Version").': <b>'.$module->getVersion().'</b><br>';
341 
342  $nextval = $module->getNextValue($mytmpinstance);
343  if ("$nextval" != $langs->trans("NotAvailable")) { // Keep " on nextval
344  $htmltooltip .= ''.$langs->trans("NextValue").': ';
345  if ($nextval) {
346  if (preg_match('/^Error/', $nextval) || $nextval == 'NotConfigured')
347  $nextval = $langs->trans($nextval);
348  $htmltooltip .= $nextval.'<br>';
349  } else {
350  $htmltooltip .= $langs->trans($module->error).'<br>';
351  }
352  }
353 
354  print '<td class="center">';
355  print $form->textwithpicto('', $htmltooltip, 1, 0);
356  print '</td>';
357 
358  print "</tr>\n";
359  }
360  }
361  }
362  closedir($handle);
363  }
364  }
365  }
366  print "</table><br>\n";
367  }
368 
369  if ($myTmpObjectArray['includedocgeneration']) {
370  /*
371  * Document templates generators
372  */
373  $setupnotempty++;
374  $type = strtolower($myTmpObjectKey);
375 
376  print load_fiche_titre($langs->trans("DocumentModules", $myTmpObjectKey), '', '');
377 
378  // Load array def with activated templates
379  $def = array();
380  $sql = "SELECT nom";
381  $sql .= " FROM ".MAIN_DB_PREFIX."document_model";
382  $sql .= " WHERE type = '".$db->escape($type)."'";
383  $sql .= " AND entity = ".$conf->entity;
384  $resql = $db->query($sql);
385  if ($resql)
386  {
387  $i = 0;
388  $num_rows = $db->num_rows($resql);
389  while ($i < $num_rows)
390  {
391  $array = $db->fetch_array($resql);
392  array_push($def, $array[0]);
393  $i++;
394  }
395  } else {
396  dol_print_error($db);
397  }
398 
399 
400  print "<table class=\"noborder\" width=\"100%\">\n";
401  print "<tr class=\"liste_titre\">\n";
402  print '<td>'.$langs->trans("Name").'</td>';
403  print '<td>'.$langs->trans("Description").'</td>';
404  print '<td class="center" width="60">'.$langs->trans("Status")."</td>\n";
405  print '<td class="center" width="60">'.$langs->trans("Default")."</td>\n";
406  print '<td class="center" width="38">'.$langs->trans("ShortInfo").'</td>';
407  print '<td class="center" width="38">'.$langs->trans("Preview").'</td>';
408  print "</tr>\n";
409 
410  clearstatcache();
411 
412  foreach ($dirmodels as $reldir)
413  {
414  foreach (array('', '/doc') as $valdir)
415  {
416  $realpath = $reldir."core/modules/".$moduledir.$valdir;
417  $dir = dol_buildpath($realpath);
418 
419  if (is_dir($dir))
420  {
421  $handle = opendir($dir);
422  if (is_resource($handle))
423  {
424  while (($file = readdir($handle)) !== false)
425  {
426  $filelist[] = $file;
427  }
428  closedir($handle);
429  arsort($filelist);
430 
431  foreach ($filelist as $file)
432  {
433  if (preg_match('/\.modules\.php$/i', $file) && preg_match('/^(pdf_|doc_)/', $file))
434  {
435  if (file_exists($dir.'/'.$file))
436  {
437  $name = substr($file, 4, dol_strlen($file) - 16);
438  $classname = substr($file, 0, dol_strlen($file) - 12);
439 
440  require_once $dir.'/'.$file;
441  $module = new $classname($db);
442 
443  $modulequalified = 1;
444  if ($module->version == 'development' && $conf->global->MAIN_FEATURES_LEVEL < 2) $modulequalified = 0;
445  if ($module->version == 'experimental' && $conf->global->MAIN_FEATURES_LEVEL < 1) $modulequalified = 0;
446 
447  if ($modulequalified)
448  {
449  print '<tr class="oddeven"><td width="100">';
450  print (empty($module->name) ? $name : $module->name);
451  print "</td><td>\n";
452  if (method_exists($module, 'info')) print $module->info($langs);
453  else print $module->description;
454  print '</td>';
455 
456  // Active
457  if (in_array($name, $def))
458  {
459  print '<td class="center">'."\n";
460  print '<a href="'.$_SERVER["PHP_SELF"].'?action=del&amp;token='.newToken().'&amp;value='.$name.'">';
461  print img_picto($langs->trans("Enabled"), 'switch_on');
462  print '</a>';
463  print '</td>';
464  } else {
465  print '<td class="center">'."\n";
466  print '<a href="'.$_SERVER["PHP_SELF"].'?action=set&amp;token='.newToken().'&amp;value='.$name.'&amp;scan_dir='.$module->scandir.'&amp;label='.urlencode($module->name).'">'.img_picto($langs->trans("Disabled"), 'switch_off').'</a>';
467  print "</td>";
468  }
469 
470  // Default
471  print '<td class="center">';
472  $constforvar = 'RECRUITMENT_'.strtoupper($myTmpObjectKey).'_ADDON';
473  if ($conf->global->$constforvar == $name) {
474  //print img_picto($langs->trans("Default"), 'on');
475  // Even if choice is the default value, we allow to disable it. Replace this with previous line if you need to disable unset
476  print '<a href="'.$_SERVER["PHP_SELF"].'?action=unsetdoc&amp;token='.newToken().'&amp;object='.urlencode(strtolower($myTmpObjectKey)).'&amp;value='.$name.'&amp;scan_dir='.$module->scandir.'&amp;label='.urlencode($module->name).'&amp;type='.urlencode($type).'" alt="'.$langs->trans("Disable").'">'.img_picto($langs->trans("Enabled"), 'on').'</a>';
477  } else {
478  print '<a href="'.$_SERVER["PHP_SELF"].'?action=setdoc&amp;token='.newToken().'&amp;object='.urlencode(strtolower($myTmpObjectKey)).'&amp;value='.$name.'&amp;scan_dir='.urlencode($module->scandir).'&amp;label='.urlencode($module->name).'" alt="'.$langs->trans("Default").'">'.img_picto($langs->trans("Disabled"), 'off').'</a>';
479  }
480  print '</td>';
481 
482  // Info
483  $htmltooltip = ''.$langs->trans("Name").': '.$module->name;
484  $htmltooltip .= '<br>'.$langs->trans("Type").': '.($module->type ? $module->type : $langs->trans("Unknown"));
485  if ($module->type == 'pdf')
486  {
487  $htmltooltip .= '<br>'.$langs->trans("Width").'/'.$langs->trans("Height").': '.$module->page_largeur.'/'.$module->page_hauteur;
488  }
489  $htmltooltip .= '<br>'.$langs->trans("Path").': '.preg_replace('/^\//', '', $realpath).'/'.$file;
490 
491  $htmltooltip .= '<br><br><u>'.$langs->trans("FeaturesSupported").':</u>';
492  $htmltooltip .= '<br>'.$langs->trans("Logo").': '.yn($module->option_logo, 1, 1);
493  $htmltooltip .= '<br>'.$langs->trans("MultiLanguage").': '.yn($module->option_multilang, 1, 1);
494 
495  print '<td class="center">';
496  print $form->textwithpicto('', $htmltooltip, 1, 0);
497  print '</td>';
498 
499  // Preview
500  print '<td class="center">';
501  if ($module->type == 'pdf')
502  {
503  print '<a href="'.$_SERVER["PHP_SELF"].'?action=specimen&module='.$name.'&object='.$myTmpObjectKey.'">'.img_object($langs->trans("Preview"), 'generic').'</a>';
504  } else {
505  print img_object($langs->trans("PreviewNotAvailable"), 'generic');
506  }
507  print '</td>';
508 
509  print "</tr>\n";
510  }
511  }
512  }
513  }
514  }
515  }
516  }
517  }
518 
519  print '</table>';
520  }
521 }
522 
523 if (empty($setupnotempty)) {
524  print '<br>'.$langs->trans("NothingToSetup");
525 }
526 
527 // Page end
528 print dol_get_fiche_end();
529 
530 llxFooter();
531 $db->close();
if(!function_exists('dol_getprefix')) dol_include_once($relpath, $classname= '')
Make an include_once using default root and alternate root if it fails.
GETPOST($paramname, $check= 'alphanohtml', $method=0, $filter=null, $options=null, $noreplace=0)
Return value of a param into GET or POST supervariable.
delDocumentModel($name, $type)
Delete document model used by doc generator.
Definition: admin.lib.php:1748
yn($yesno, $case=1, $color=0)
Return yes or no in current language.
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:575
addDocumentModel($name, $type, $label= '', $description= '')
Add document model used by doc generator.
Definition: admin.lib.php:1717
dol_buildpath($path, $type=0, $returnemptyifnotfound=0)
Return path of url or filesystem.
llxHeader()
Empty header.
Definition: wrapper.php:45
setEventMessages($mesg, $mesgs, $style= 'mesgs', $messagekey= '')
Set event messages in dol_events session object.
Class to manage generation of HTML components Only common components must be here.
load_fiche_titre($titre, $morehtmlright= '', $picto= 'generic', $pictoisfullpath=0, $id= '', $morecssontable= '', $morehtmlcenter= '')
Load a title with picto.
dol_strlen($string, $stringencoding= 'UTF-8')
Make a strlen call.
dolibarr_del_const($db, $name, $entity=1)
Effacement d&#39;une constante dans la base de donnees.
Definition: admin.lib.php:499
img_picto($titlealt, $picto, $moreatt= '', $pictoisfullpath=false, $srconly=0, $notitle=0, $alt= '', $morecss= '', $marginleftonlyshort=2)
Show picto whatever it&#39;s its name (generic function)
dol_syslog($message, $level=LOG_INFO, $ident=0, $suffixinfilename= '', $restricttologhandler= '', $logcontext=null)
Write log message into outputs.
if(!GETPOST('transkey', 'alphanohtml')&&!GETPOST('transphrase', 'alphanohtml')) else
View.
Definition: notice.php:44
img_object($titlealt, $picto, $moreatt= '', $pictoisfullpath=false, $srconly=0, $notitle=0)
Show a picto called object_picto (generic function)
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 ...
recruitmentAdminPrepareHead()
Prepare admin pages header.
print $_SERVER["PHP_SELF"]
Edit parameters.
dol_get_fiche_head($links=array(), $active= '', $title= '', $notab=0, $picto= '', $pictoisfullpath=0, $morehtmlright= '', $morecss= '', $limittoshow=0, $moretabssuffix= '')
Show tabs of a record.
print
Draft customers invoices.
Definition: index.php:89
if(!empty($conf->facture->enabled)&&$user->rights->facture->lire) if((!empty($conf->fournisseur->enabled)&&empty($conf->global->MAIN_USE_NEW_SUPPLIERMOD)||!empty($conf->supplier_invoice->enabled))&&$user->rights->fournisseur->facture->lire) if(!empty($conf->don->enabled)&&$user->rights->don->lire) if(!empty($conf->tax->enabled)&&$user->rights->tax->charges->lire) if(!empty($conf->facture->enabled)&&!empty($conf->commande->enabled)&&$user->rights->commande->lire &&empty($conf->global->WORKFLOW_DISABLE_CREATE_INVOICE_FROM_ORDER)) if(!empty($conf->facture->enabled)&&$user->rights->facture->lire) if((!empty($conf->fournisseur->enabled)&&empty($conf->global->MAIN_USE_NEW_SUPPLIERMOD)||!empty($conf->supplier_invoice->enabled))&&$user->rights->fournisseur->facture->lire) $resql
Social contributions to pay.
Definition: index.php:1232
dol_print_error($db= '', $error= '', $errors=null)
Displays error message system with all the information to facilitate the diagnosis and the escalation...
newToken()
Return the value of token currently saved into session with name &#39;newtoken&#39;.
dol_get_fiche_end($notab=0)
Return tab footer of a card.
print $_SERVER["PHP_SELF"] n
Edit parameters.
Definition: categories.php:101
llxFooter()
Empty footer.
Definition: wrapper.php:59
if(!defined('CSRFCHECK_WITH_TOKEN')) define('CSRFCHECK_WITH_TOKEN'
Draft customers invoices.