35 global $db, $langs, $conf;
42 $head[$h][0] =
dol_buildpath(
"/hrm/evaluation_card.php", 1).
'?id='.$object->id;
43 $head[$h][1] = $langs->trans(
"EvaluationCard");
44 $head[$h][2] =
'card';
47 if (isset($object->fields[
'note_public']) || isset($object->fields[
'note_private'])) {
49 if (!empty($object->note_private)) {
52 if (!empty($object->note_public)) {
55 $head[$h][0] =
dol_buildpath(
'/hrm/evaluation_note.php', 1).
'?id='.$object->id;
56 $head[$h][1] = $langs->trans(
'Notes');
58 $head[$h][1] .= (empty($conf->global->MAIN_OPTIMIZEFORTEXTBROWSER) ?
'<span class="badge marginleftonlyshort">'.$nbNote.
'</span>' :
'');
60 $head[$h][2] =
'note';
64 require_once DOL_DOCUMENT_ROOT.
'/core/lib/files.lib.php';
65 require_once DOL_DOCUMENT_ROOT.
'/core/class/link.class.php';
67 $nbFiles = count(
dol_dir_list($upload_dir,
'files', 0,
'',
'(\.meta|_preview.*\.png)$'));
68 $nbLinks =
Link::count($db, $object->element, $object->id);
69 $head[$h][0] =
dol_buildpath(
"/hrm/evaluation_document.php", 1).
'?id='.$object->id;
70 $head[$h][1] = $langs->trans(
'Documents');
71 if (($nbFiles + $nbLinks) > 0) {
72 $head[$h][1] .=
'<span class="badge marginleftonlyshort">'.($nbFiles + $nbLinks).
'</span>';
74 $head[$h][2] =
'document';
77 $head[$h][0] =
dol_buildpath(
"/hrm/evaluation_agenda.php", 1).
'?id='.$object->id;
78 $head[$h][1] = $langs->trans(
"Events");
79 $head[$h][2] =
'agenda';
103 $legendSkills =
'<div style="font-style:italic;">
104 ' . $langs->trans(
'legend') .
'
105 <table class="border" width="100%">
107 <td><span style="vertical-align:middle" class="toohappy diffnote little"></span>
108 ' . $langs->trans(
'CompetenceAcquiredByOneOrMore') .
'</td>
111 <td><span style="vertical-align:middle" class="veryhappy diffnote little"></span>
112 ' . $langs->trans(
'MaxlevelGreaterThan') .
'</td>
115 <td><span style="vertical-align:middle" class="happy diffnote little"></span>
116 ' . $langs->trans(
'MaxLevelEqualTo') .
'</td>
119 <td><span style="vertical-align:middle" class="sad diffnote little"></span>
120 ' . $langs->trans(
'MaxLevelLowerThan') .
'</td>
123 <td><span style="vertical-align:middle" class="toosad diffnote little"></span>
124 ' . $langs->trans(
'SkillNotAcquired') .
'</td>
128 return $legendSkills;
static count($dbs, $objecttype, $objectid)
Return nb of links.
dol_dir_list($path, $types="all", $recursive=0, $filter="", $excludefilter=null, $sortcriteria="name", $sortorder=SORT_ASC, $mode=0, $nohook=0, $relativename="", $donotfollowsymlinks=0, $nbsecondsold=0)
Scan a directory and return a list of files/directories.
dol_buildpath($path, $type=0, $returnemptyifnotfound=0)
Return path of url or filesystem.
dol_sanitizeFileName($str, $newstr='_', $unaccent=1)
Clean a string to use it as a file name.
complete_head_from_modules($conf, $langs, $object, &$head, &$h, $type, $mode='add', $filterorigmodule='')
Complete or removed entries into a head array (used to build tabs).
evaluationPrepareHead($object)
Prepare array of tabs for Evaluation.