32require
'../main.inc.php';
33require_once DOL_DOCUMENT_ROOT .
'/core/class/html.formcompany.class.php';
34require_once DOL_DOCUMENT_ROOT .
'/core/class/html.formfile.class.php';
35require_once DOL_DOCUMENT_ROOT .
'/core/class/html.formprojet.class.php';
36require_once DOL_DOCUMENT_ROOT .
'/hrm/class/skill.class.php';
37require_once DOL_DOCUMENT_ROOT .
'/hrm/lib/hrm_skill.lib.php';
49$langs->loadLangs(array(
'hrm',
'other',
'products'));
54$action =
GETPOST(
'action',
'aZ09');
55$confirm =
GETPOST(
'confirm',
'alpha');
57$contextpage =
GETPOST(
'contextpage',
'aZ') ?
GETPOST(
'contextpage',
'aZ') :
'skillcard';
58$backtopage =
GETPOST(
'backtopage',
'alpha');
59$backtopageforcancel =
GETPOST(
'backtopageforcancel',
'alpha');
66$hookmanager->initHooks(array(
'skillcard',
'globalcard'));
69$extrafields->fetch_name_optionals_label(
$object->table_element);
71$search_array_options = $extrafields->getOptionalsFromPost(
$object->table_element,
'',
'search_');
75$search_all =
GETPOST(
"search_all",
'alpha');
77foreach (
$object->fields as $key => $val) {
78 if (
GETPOST(
'search_' . $key,
'alpha')) {
79 $search[$key] =
GETPOST(
'search_' . $key,
'alpha');
83if (empty($action) && empty($id) && empty($ref)) {
88include DOL_DOCUMENT_ROOT .
'/core/actions_fetchobject.inc.php';
91$permissiontoread = $user->hasRight(
'hrm',
'all',
'read');
92$permissiontoadd = $user->hasRight(
'hrm',
'all',
'write');
93$permissiontodelete = $user->hasRight(
'hrm',
'all',
'delete');
95$upload_dir = $conf->hrm->multidir_output[isset(
$object->entity) ?
$object->entity : 1] .
'/skill';
102if (empty($conf->hrm->enabled)) {
105if (!$permissiontoread || ($action ===
'create' && !$permissiontoadd)) {
109$MaxNumberSkill =
getDolGlobalInt(
'HRM_MAXRANK', Skill::DEFAULT_MAX_RANK_PER_SKILL);
116$parameters = array();
117$reshook = $hookmanager->executeHooks(
'doActions', $parameters, $object, $action);
122if (empty($reshook)) {
125 $backurlforlist = DOL_URL_ROOT.
'/hrm/skill_list.php';
127 if (empty($backtopage) || ($cancel && empty($id))) {
128 if (empty($backtopage) || ($cancel && strpos($backtopage,
'__ID__'))) {
129 if (empty($id) && (($action !=
'add' && $action !=
'create') || $cancel)) {
130 $backtopage = $backurlforlist;
132 $backtopage = DOL_URL_ROOT.
'/hrm/skill_card.php?id=' . (
$id > 0 ?
$id :
'__ID__');
137 $triggermodname =
'HRM_SKILL_MODIFY';
140 $skilldetArray =
GETPOST(
"descriptionline",
"array:alphanohtml");
143 if (is_array($skilldetArray) && count($skilldetArray) > 0) {
144 if ($action ==
'update' && $permissiontoadd) {
145 foreach ($skilldetArray as $key => $SkValueToUpdate) {
147 $res = $skilldetObj->fetch($key);
149 $skilldetObj->description = $SkValueToUpdate;
150 $resupd = $skilldetObj->update($user);
163 if (in_array($action, array(
"confirm_delete",
"update"))) {
167 include DOL_DOCUMENT_ROOT.
'/core/actions_addupdatedelete.inc.php';
170 if (is_array($skilldetArray) && count($skilldetArray) > 0) {
171 if ($action ==
'add' && $permissiontoadd) {
172 $arraySkill =
$object->fetchLines();
173 '@phan-var-force Skilldet[] $arraySkill';
176 foreach ($arraySkill as $skilldet) {
177 if ($skilldet->rankorder != 0) {
178 if (isset($skilldetArray[$index])) {
179 $SkValueToUpdate = $skilldetArray[$index];
180 $skilldet->description = !empty($SkValueToUpdate) ? $SkValueToUpdate : $skilldet->description;
181 $resupd = $skilldet->update($user);
189 header(
"Location: ".$_SERVER[
"PHP_SELF"].
"?id=".
$object->id);
197 include DOL_DOCUMENT_ROOT .
'/core/actions_dellink.inc.php';
200 include DOL_DOCUMENT_ROOT .
'/core/actions_printing.inc.php';
206 include DOL_DOCUMENT_ROOT .
'/core/actions_builddoc.inc.php';
208 if ($action ==
'set_thirdparty' && $permissiontoadd) {
209 $object->setValueFrom(
'fk_soc',
GETPOSTINT(
'fk_soc'),
'',
null,
'date',
'', $user, $triggermodname);
211 if ($action ==
'classin' && $permissiontoadd) {
216 $triggersendname =
'HRM_SKILL_SENTBYMAIL';
217 $autocopy =
'MAIN_MAIL_AUTOCOPY_SKILL_TO';
218 $trackid =
'skill' .
$object->id;
219 include DOL_DOCUMENT_ROOT .
'/core/actions_sendmails.inc.php';
221 if ($action ==
'confirm_clone' && $confirm !=
'yes') {
225 if ($action ==
'confirm_clone' && $confirm ==
'yes' && $permissiontoadd) {
227 header(
"Location: ".$_SERVER[
"PHP_SELF"].
"?id=".$id);
237$form =
new Form($db);
241$title = $langs->trans(
"Skill");
247if ($action ==
'create') {
250 print
'<form method="POST" action="' . $_SERVER[
"PHP_SELF"] .
'">';
251 print
'<input type="hidden" name="token" value="' .
newToken() .
'">';
252 print
'<input type="hidden" name="action" value="add">';
253 $backtopage .= (strpos($backtopage,
'?') > 0 ?
'&' :
'?') .
"objecttype=job";
255 print
'<input type="hidden" name="backtopage" value="' . $backtopage .
'">';
257 if ($backtopageforcancel) {
258 print
'<input type="hidden" name="backtopageforcancel" value="' . $backtopageforcancel .
'">';
263 print
'<table class="border centpercent tableforfieldcreate">' .
"\n";
266 include DOL_DOCUMENT_ROOT .
'/core/tpl/commonfields_add.tpl.php';
269 include DOL_DOCUMENT_ROOT.
'/core/tpl/extrafields_add.tpl.php';
276 print
'</table>' .
"\n";
279 print
'<table class="border centpercent =">' .
"\n";
280 for ($i = 1; $i <= $MaxNumberSkill; $i++) {
281 print
'<tr><td class="titlefieldcreate tdtop">'. $langs->trans(
'Description') .
' ' . $langs->trans(
'rank') .
' ' . $i .
'</td>';
282 print
'<td class="valuefieldcreate"><textarea name="descriptionline[]" rows="5" class="flat minwidth100" style="margin-top: 5px; width: 90%"></textarea></td>';
288 print
'<div class="center">';
289 print
'<input type="submit" class="button" name="add" value="' .
dol_escape_htmltag($langs->trans(
"Create")) .
'">';
291 print
'<input type="' . ($backtopage ?
"submit" :
"button") .
'" class="button button-cancel" name="cancel" value="' .
dol_escape_htmltag($langs->trans(
"Cancel")) .
'"' . ($backtopage ?
'' :
' onclick="history.go(-1)"') .
'>';
301if (($id || $ref) && $action ==
'edit') {
304 print
'<form method="POST" action="' . $_SERVER[
"PHP_SELF"] .
'">';
305 print
'<input type="hidden" name="token" value="' .
newToken() .
'">';
306 print
'<input type="hidden" name="action" value="update">';
307 print
'<input type="hidden" name="id" value="' .
$object->id .
'">';
309 print
'<input type="hidden" name="backtopage" value="' . $backtopage .
'">';
311 if ($backtopageforcancel) {
312 print
'<input type="hidden" name="backtopageforcancel" value="' . $backtopageforcancel .
'">';
317 print
'<table class="border centpercent tableforfieldedit">' .
"\n";
320 include DOL_DOCUMENT_ROOT .
'/core/tpl/commonfields_edit.tpl.php';
323 include DOL_DOCUMENT_ROOT.
'/core/tpl/extrafields_edit.tpl.php';
330 $SkilldetRecords =
$object->fetchLines();
331 '@phan-var-force Skilldet[] $SkilldetRecords';
333 if (is_array($SkilldetRecords) && count($SkilldetRecords) == 0) {
337 if (is_array($SkilldetRecords) && count($SkilldetRecords) > 0) {
339 foreach ($SkilldetRecords as $sk) {
340 if ($sk->rankorder > $MaxNumberSkill) {
344 print
'<table class="border centpercent =">' .
"\n";
346 foreach ($sk->fields as $key => $val) {
347 if (abs($val[
'visible']) != 1 && abs($val[
'visible']) != 3 && abs($val[
'visible']) != 4) {
351 if (array_key_exists(
'enabled', $val) && isset($val[
'enabled']) && !
verifCond($val[
'enabled'])) {
355 print
'<tr class="field_' . $key .
'"><td';
356 print
' class="titlefieldcreate';
357 if (isset($val[
'notnull']) && $val[
'notnull'] > 0) {
358 print
' fieldrequired';
360 if (preg_match(
'/^(text|html)/', $val[
'type'])) {
367 print $langs->trans($val[
'label']).
' '.$langs->trans(
'rank').
' '.$sk->rankorder;
370 print
'<td class="valuefieldcreate">';
385 $check =
'restricthtml';
387 $skilldetArray =
GETPOST(
"descriptionline",
"array");
388 if (empty($skilldetArray)) {
389 $value = GETPOSTISSET($key) ?
GETPOST($key, $check) : $sk->$key;
391 $value = $skilldetArray[$sk->id];
400 if (!empty($val[
'noteditable'])) {
401 print $sk->showOutputField($val, $key, $value,
'',
'',
'', 0);
404 print $sk->showInputField($val, $key, $value,
"",
"line[" . $sk->id .
"]",
"",
"");
416 print
'<div class="center"><input type="submit" class="button button-save" name="save" value="' . $langs->trans(
"Save") .
'">';
417 print
' <input type="submit" class="button button-cancel" name="cancel" value="' . $langs->trans(
"Cancel") .
'">';
425if (
$object->id > 0 && (empty($action) || ($action !=
'edit' && $action !=
'create'))) {
426 $res =
$object->fetch_optionals();
434 if ($action ==
'delete') {
435 $formconfirm = $form->formconfirm(
dolBuildUrl($_SERVER[
"PHP_SELF"], [
'id' =>
$object->id]), $langs->trans(
'DeleteSkill'), $langs->trans(
'ConfirmDeleteObject'),
'confirm_delete',
'', 0, 1);
438 if ($action ==
'deleteline') {
439 $formconfirm = $form->formconfirm($_SERVER[
"PHP_SELF"] .
'?id=' .
$object->id .
'&lineid=' . $lineid, $langs->trans(
'DeleteLine'), $langs->trans(
'ConfirmDeleteLine'),
'confirm_deleteline',
'', 0, 1);
442 if ($action ===
'clone') {
443 $formquestion = array(
444 array(
'type' =>
'text',
'name' =>
'clone_label',
'label' => $langs->trans(
"Label"),
'value' => $langs->trans(
"CopyOf").
' '.
$object->label),
446 $formconfirm = $form->formconfirm($_SERVER[
"PHP_SELF"].
'?id='.
$object->id, $langs->trans(
'ToClone'), $langs->trans(
'ConfirmCloneAsk',
$object->label),
'confirm_clone', $formquestion,
'yes', 1, 280);
450 $parameters = array(
'formConfirm' => $formconfirm,
'lineid' => $lineid);
451 $reshook = $hookmanager->executeHooks(
'formConfirm', $parameters, $object, $action);
452 if (empty($reshook)) {
453 $formconfirm .= $hookmanager->resPrint;
454 } elseif ($reshook > 0) {
455 $formconfirm = $hookmanager->resPrint;
464 $linkback =
'<a href="' . DOL_URL_ROOT.
'/hrm/skill_list.php?restore_lastsearch_values=1' . (!empty($socid) ?
'&socid=' . $socid :
'') .
'">' . $langs->trans(
"BackToList") .
'</a>';
467 $morehtmlref =
'<div class="refid">';
468 $morehtmlref .=
$object->label;
469 $morehtmlref .=
'</div>';
470 dol_banner_tab($object,
'id', $linkback, 1,
'rowid',
'rowid', $morehtmlref);
473 print
'<div class="fichecenter">';
474 print
'<div class="fichehalfleft">';
475 print
'<div class="underbanner clearboth"></div>';
476 print
'<table class="border centpercent tableforfield">' .
"\n";
478 $object->fields[
'label'][
'visible'] = 0;
479 include DOL_DOCUMENT_ROOT .
'/core/tpl/commonfields_view.tpl.php';
482 include DOL_DOCUMENT_ROOT.
'/core/tpl/extrafields_view.tpl.php';
489 print
'<div class="clearboth"></div>';
498 if ($action !=
'presend' && $action !=
'editline') {
499 print
'<div class="tabsAction">' .
"\n";
500 $parameters = array();
501 $reshook = $hookmanager->executeHooks(
'addMoreActionsButtons', $parameters, $object, $action);
506 if (empty($reshook)) {
508 if (
$object->status == $object::STATUS_VALIDATED) {
509 print
dolGetButtonAction($langs->trans(
'SetToDraft'),
'',
'default', $_SERVER[
"PHP_SELF"] .
'?id=' .
$object->id .
'&action=confirm_setdraft&confirm=yes&token=' .
newToken(),
'', $permissiontoadd);
512 print
dolGetButtonAction($langs->trans(
'Modify'),
'',
'default', $_SERVER[
"PHP_SELF"] .
'?id=' .
$object->id .
'&action=edit&token=' .
newToken(),
'', $permissiontoadd);
515 if ($permissiontoadd) {
519 print
dolGetButtonAction($langs->trans(
'Delete'),
'',
'delete', $_SERVER[
'PHP_SELF'] .
'?id=' .
$object->id .
'&action=delete&token=' .
newToken(),
'', $permissiontodelete);
521 print
'</div>' .
"\n";
528if ($action !=
"create" && $action !=
"edit") {
529 require_once DOL_DOCUMENT_ROOT .
'/core/class/html.formcompany.class.php';
530 require_once DOL_DOCUMENT_ROOT .
'/core/lib/date.lib.php';
531 require_once DOL_DOCUMENT_ROOT .
'/core/lib/company.lib.php';
534 require_once __DIR__ .
'/class/skilldet.class.php';
539 $action =
GETPOST(
'action',
'aZ09') ?
GETPOST(
'action',
'aZ09') :
'view';
540 $massaction =
GETPOST(
'massaction',
'alpha');
542 $confirm =
GETPOST(
'confirm',
'alpha');
543 $cancel =
GETPOST(
'cancel',
'alpha');
544 $toselect =
GETPOST(
'toselect',
'array:int');
545 $contextpage =
GETPOST(
'contextpage',
'aZ') ?
GETPOST(
'contextpage',
'aZ') :
'skilldetlist';
546 $backtopage =
GETPOST(
'backtopage',
'alpha');
547 $optioncss =
GETPOST(
'optioncss',
'aZ');
553 $sortfield =
GETPOST(
'sortfield',
'aZ09comma');
554 $sortorder =
GETPOST(
'sortorder',
'aZ09comma');
556 if (empty($page) || $page < 0 ||
GETPOST(
'button_search',
'alpha') ||
GETPOST(
'button_removefilter',
'alpha')) {
560 $offset = $limit * $page;
561 $pageprev = $page - 1;
562 $pagenext = $page + 1;
571 reset($objectline->fields);
572 $sortfield =
"t." . key($objectline->fields);
579 $search_all =
GETPOST(
'search_all',
'alphanohtml');
581 foreach ($objectline->fields as $key => $val) {
582 if (
GETPOST(
'search_' . $key,
'alpha') !==
'') {
583 $search[$key] =
GETPOST(
'search_' . $key,
'alpha');
585 if (preg_match(
'/^(date|timestamp|datetime)/', $val[
'type'])) {
592 $fieldstosearchall = array();
593 foreach ($objectline->fields as $key => $val) {
594 if (!empty($val[
'searchall'])) {
595 $fieldstosearchall[
't.' . $key] = $val[
'label'];
600 $arrayfields = array();
601 foreach ($objectline->fields as $key => $val) {
603 if (!empty($val[
'visible'])) {
604 $visible = (int)
dol_eval((
string) $val[
'visible'], 1, 1,
'1');
605 $arrayfields[
't.' . $key] = array(
606 'label' => $val[
'label'],
607 'checked' => (($visible < 0) ? 0 : 1),
608 'enabled' => (abs($visible) != 3 && (bool)
dol_eval((string) $val[
'enabled'], 1)),
609 'position' => $val[
'position'],
610 'help' => isset($val[
'help']) ? $val[
'help'] :
''
615 $objectline->fields =
dol_sort_array($objectline->fields,
'position');
621 $form =
new Form($db);
626 $title = $langs->transnoentitiesnoconv(
"Skilldets");
629 $nbtotalofrecords =
'';
634 $sql .= $objectline->getFieldList(
't');
635 $sql .=
" FROM " . MAIN_DB_PREFIX . $objectline->table_element .
" as t";
636 if ($objectline->ismultientitymanaged == 1) {
637 $sql .=
" WHERE t.entity IN (" .
getEntity($objectline->element) .
")";
639 $sql .=
" WHERE 1 = 1 ";
641 $sql .=
" AND fk_skill = ".((int) $id);
642 $sql .=
" AND rankorder <> 0";
644 $resql = $db->query($sql);
645 $nbtotalofrecords = $db->num_rows($resql);
646 $num = $db->num_rows($resql);
648 print
'<form method="POST" id="searchFormList" action="' . $_SERVER[
"PHP_SELF"] .
'">' .
"\n";
649 if ($optioncss !=
'') {
650 print
'<input type="hidden" name="optioncss" value="' . $optioncss .
'">';
652 print
'<input type="hidden" name="token" value="' .
newToken() .
'">';
653 print
'<input type="hidden" name="formfilteraction" id="formfilteraction" value="list">';
654 print
'<input type="hidden" name="action" value="list">';
655 print
'<input type="hidden" name="sortfield" value="' . $sortfield .
'">';
656 print
'<input type="hidden" name="sortorder" value="' . $sortorder .
'">';
657 print
'<input type="hidden" name="page" value="' . $page .
'">';
658 print
'<input type="hidden" name="contextpage" value="' . $contextpage .
'">';
660 print
'<input type="hidden" name="id" value="' .
$id .
'">';
663 $param_fk =
"&fk_skill=" .
$id .
"&fk_user_creat=" . (!empty($user->rowid) ? $user->rowid : 0);
666 $massactionbutton =
"";
669 print_barre_liste($title, $page, $_SERVER[
"PHP_SELF"], $param, $sortfield, $sortorder, $massactionbutton, $num, $nbtotalofrecords,
'object_' .
$object->picto, 0,
'',
'', 0, 0, 0, 1);
672 $topicmail =
"SendSkilldetRef";
673 $modelmail =
"skilldet";
675 $trackid =
'xxxx' .
$object->id;
679 foreach ($fieldstosearchall as $key => $val) {
680 $fieldstosearchall[$key] = $langs->trans($val);
682 print
'<div class="divsearchfieldfilter">' . $langs->trans(
"FilterOnInto", $search_all) . implode(
', ', $fieldstosearchall) .
'</div>';
690 $parameters = array();
691 $reshook = $hookmanager->executeHooks(
'printFieldPreListTitle', $parameters, $objectline);
692 if (empty($reshook)) {
693 $moreforfilter .= $hookmanager->resPrint;
695 $moreforfilter = $hookmanager->resPrint;
698 if (!empty($moreforfilter)) {
699 print
'<div class="liste_titre liste_titre_bydiv centpercent">';
700 print $moreforfilter;
704 $varpage = empty($contextpage) ? $_SERVER[
"PHP_SELF"] : $contextpage;
708 print
'<div class="div-table-responsive">';
709 print
'<table class="tagtable nobottomiftotal liste' . ($moreforfilter ?
" listwithfilterbefore" :
"") .
'">' .
"\n";
714 print
'<tr class="liste_titre">';
715 foreach ($objectline->fields as $key => $val) {
726 if (!empty($arrayfields[
't.' . $key][
'checked'])) {
727 print
getTitleFieldOfList($arrayfields[
't.' . $key][
'label'], 0, $_SERVER[
'PHP_SELF'],
't.' . $key,
'', $param, (!empty($cssforfield) ?
'class="' . $cssforfield .
'"' :
''), $sortfield, $sortorder, (!empty($cssforfield) ? $cssforfield .
' ' :
'')) .
"\n";
732 print
'</tr>' .
"\n";
741 while ($i < ($limit ? min($num, $limit) : $num)) {
742 $obj = $db->fetch_object($resql);
747 if ($obj->rankorder > $MaxNumberSkill) {
752 $objectline->setVarsFromFetchObj($obj);
755 print
'<tr class="oddeven">';
756 foreach ($objectline->fields as $key => $val) {
775 if (!empty($arrayfields[
't.' . $key][
'checked'])) {
776 print
'<td' . (empty($cssforfield) ?
'' :
' class="' . $cssforfield .
'"') .
'>';
777 if ($key ==
'status') {
778 print $objectline->getLibStatut(5);
779 } elseif ($key ==
'rowid') {
780 print $objectline->showOutputField($val, $key, (
string) $objectline->id,
'');
782 print
'<a class="timeline-btn" href="' . DOL_MAIN_URL_ROOT .
'/comm/action/skilldet_card.php?action=edit&id=' . $objectline->id .
'"><i class="fa fa-pencil" title="' . $langs->trans(
"Modify") .
'" ></i></a>';
784 print $objectline->showOutputField($val, $key, $objectline->$key,
'');
792 if (!empty($val[
'isameasure']) && $val[
'isameasure'] == 1) {
802 $totalarray[
'val'][
't.' . $key] += $objectline->$key;
824 $parameters = array(
'arrayfields' => $arrayfields,
'object' => $objectline,
'obj' => $obj,
'i' => $i,
'totalarray' => &
$totalarray);
825 $reshook = $hookmanager->executeHooks(
'printFieldListValue', $parameters, $objectline);
826 print $hookmanager->resPrint;
835 print
'</tr>' .
"\n";
845 foreach ($arrayfields as $key => $val) {
846 if (!empty($val[
'checked'])) {
850 print
'<tr><td colspan="' . $colspan .
'"><span class="opacitymedium">' . $langs->trans(
"NoRecordFound") .
'</span></td></tr>';
853 if (!empty($resql)) {
857 $parameters = array(
'arrayfields' => $arrayfields,
'sql' => $sql);
858 $reshook = $hookmanager->executeHooks(
'printFieldListFooter', $parameters, $objectline);
859 print $hookmanager->resPrint;
861 print
'</table>' .
"\n";
862 print
'</div>' .
"\n";
864 print
'</form>' .
"\n";
886 print
'<div class="fichecenter"><div class="fichehalfleft">';
889 $tmparray = $form->showLinkToObjectBlock($object, array(), array(
'skill'), 1);
890 $linktoelem = $tmparray[
'linktoelem'];
891 $htmltoenteralink = $tmparray[
'htmltoenteralink'];
892 print $htmltoenteralink;
894 $somethingshown = $form->showLinkedObjectBlock($object, $linktoelem);
896 print
'</div><div class="fichehalfright">';
900 $morehtmlcenter =
dolGetButtonTitle($langs->trans(
'SeeAll'),
'',
'fa fa-bars imgforviewmode', DOL_URL_ROOT.
'/hrm/skill_agenda.php?id='.
$object->id);
903 include_once DOL_DOCUMENT_ROOT .
'/core/class/html.formactions.class.php';
905 $somethingshown = $formactions->showactions($object,
$object->element .
'@' .
$object->module, (is_object(
$object->thirdparty) ?
$object->thirdparty->id : 0), 1,
'', $MAXEVENT,
'', $morehtmlcenter);
907 print
'</div></div>';
$id
Support class for third parties, contacts, members, users or resources.
if(! $sortfield) if(! $sortorder) $object
llxFooter($comment='', $zone='private', $disabledoutputofmessages=0)
Empty footer.
if(!defined('NOREQUIRESOC')) if(!defined( 'NOREQUIRETRAN')) if(!defined('NOTOKENRENEWAL')) if(!defined( 'NOREQUIREMENU')) if(!defined('NOREQUIREHTML')) if(!defined( 'NOREQUIREAJAX')) llxHeader($head='', $title='', $help_url='', $target='', $disablejs=0, $disablehead=0, $arrayofjs='', $arrayofcss='', $morequerystring='', $morecssonbody='', $replacemainareaby='', $disablenofollow=0, $disablenoindex=0)
Empty header.
dol_now($mode='gmt')
Return date for now.
verifCond($strToEvaluate, $onlysimplestring='1')
Verify if condition in string is ok or not.
dol_mktime($hour, $minute, $second, $month, $day, $year, $gm='auto', $check=1)
Return a timestamp date built from detailed information (by default a local PHP server timestamp) Rep...
setEventMessages($mesg, $mesgs, $style='mesgs', $messagekey='', $noduplicate=0, $attop=0)
Set event messages in dol_events session object.
print_barre_liste($title, $page, $file, $options='', $sortfield='', $sortorder='', $morehtmlcenter='', $num=-1, $totalnboflines='', $picto='generic', $pictoisfullpath=0, $morehtmlright='', $morecss='', $limit=-1, $selectlimitsuffix=0, $hidenavigation=0, $pagenavastextinput=0, $morehtmlrightbeforearrow='')
Print a title with navigation controls for pagination.
GETPOSTINT($paramname, $method=0)
Return the value of a $_GET or $_POST supervariable, converted into integer.
dolBuildUrl($url, $params=[], $addtoken=false)
Return path of url.
dol_get_fiche_head($links=array(), $active='', $title='', $notab=0, $picto='', $pictoisfullpath=0, $morehtmlright='', $morecss='', $limittoshow=0, $moretabssuffix='', $dragdropfile=0, $morecssdiv='')
Show tabs of a record.
dolGetButtonTitle($label, $helpText='', $iconClass='fa fa-file', $url='', $id='', $status=1, $params=array())
Function dolGetButtonTitle : this kind of buttons are used in title in list.
dol_get_fiche_end($notab=0)
Return tab footer of a card.
dol_eval($s, $returnvalue=1, $hideerrors=1, $onlysimplestring='1')
Replace eval function to add more security.
setEventMessage($mesgs, $style='mesgs', $noduplicate=0, $attop=0)
Set event message in dol_events session object.
getDolGlobalInt($key, $default=0)
Return a Dolibarr global constant int value.
dol_sort_array(&$array, $index, $order='asc', $natsort=0, $case_sensitive=0, $keepindex=0)
Advanced sort array by the value of a given key, which produces ascending (default) or descending out...
newToken()
Return the value of token currently saved into session with name 'newtoken'.
dolGetButtonAction($label, $text='', $actionType='default', $url='', $id='', $userRight=1, $params=array())
Function dolGetButtonAction.
getTitleFieldOfList($name, $thead=0, $file="", $field="", $begin="", $moreparam="", $moreattrib="", $sortfield="", $sortorder="", $prefix="", $disablesortlink=0, $tooltip='', $forcenowrapcolumntitle=0)
Get title line of an array.
GETPOST($paramname, $check='alphanohtml', $method=0, $filter=null, $options=null, $noreplace=0)
Return value of a param into GET or POST supervariable.
dol_buildpath($path, $type=0, $returnemptyifnotfound=0)
Return path of url or filesystem.
load_fiche_titre($title, $morehtmlright='', $picto='generic', $pictoisfullpath=0, $id='', $morecssontable='', $morehtmlcenter='', $morecssonpicto='widthpictotitle')
Load a title with picto.
getEntity($element, $shared=1, $currentobject=null)
Get list of entity id to use.
dol_escape_htmltag($stringtoescape, $keepb=0, $keepn=0, $noescapetags='', $escapeonlyhtmltags=0, $cleanalsojavascript=0)
Returns text escaped for inclusion in HTML alt or title or value tags, or into values of HTML input f...
skillPrepareHead($object)
Prepare array of tabs for Skill.
accessforbidden($message='', $printheader=1, $printfooter=1, $showonlymessage=0, $params=null)
Show a message to say access is forbidden and stop program.