26require_once
'../main.inc.php';
27require_once DOL_DOCUMENT_ROOT.
'/recruitment/class/recruitmentjobposition.class.php';
28require_once DOL_DOCUMENT_ROOT.
'/recruitment/lib/recruitment_recruitmentjobposition.lib.php';
31$langs->loadLangs(array(
"recruitment",
"companies"));
36$action =
GETPOST(
'action',
'aZ09');
37$cancel =
GETPOST(
'cancel',
'aZ09');
38$backtopage =
GETPOST(
'backtopage',
'alpha');
43$diroutputmassaction = $conf->recruitment->dir_output.
'/temp/massgeneration/'.$user->id;
44$hookmanager->initHooks(array(
'recruitmentjobpositionnote',
'globalcard'));
46$extrafields->fetch_name_optionals_label($object->table_element);
54include DOL_DOCUMENT_ROOT.
'/core/actions_fetchobject.inc.php';
55if ($id > 0 || !empty($ref)) {
56 $upload_dir = $conf->recruitment->multidir_output[!empty($object->entity) ? $object->entity : $conf->entity].
"/".$object->id;
59$permissionnote = $user->hasRight(
'recruitment',
'recruitmentjobposition',
'write');
60$permissiontoadd = $user->hasRight(
'recruitment',
'recruitmentjobposition',
'write');
65$isdraft = (($object->status == $object::STATUS_DRAFT) ? 1 : 0);
66$result =
restrictedArea($user,
'recruitment', $object->id,
'recruitment_recruitmentjobposition',
'recruitmentjobposition',
'',
'rowid', $isdraft);
73$reshook = $hookmanager->executeHooks(
'doActions', array(), $object, $action);
78 include DOL_DOCUMENT_ROOT.
'/core/actions_setnotes.inc.php';
88$title = $object->ref.
" - ".$langs->trans(
'Notes');
92if ($id > 0 || !empty($ref)) {
93 $object->fetch_thirdparty();
97 print
dol_get_fiche_head($head,
'note', $langs->trans(
"RecruitmentJobPosition"), -1, $object->picto);
100 $linkback =
'<a href="'.dol_buildpath(
'/recruitment/recruitmentjobposition_list.php', 1).
'?restore_lastsearch_values=1'.(!empty($socid) ?
'&socid='.$socid :
'').
'">'.$langs->trans(
"BackToList").
'</a>';
102 $morehtmlref =
'<div class="refidno">';
111 if (isModEnabled(
'project')) {
112 $langs->load(
"projects");
113 $morehtmlref .= $langs->trans(
'Project').
' ';
114 if ($permissiontoadd) {
115 if ($action !=
'classify') {
117 $morehtmlref .=
' : ';
119 if ($action ==
'classify') {
121 $morehtmlref .=
'<form method="post" action="'.$_SERVER[
'PHP_SELF'].
'?id='.$object->id.
'">';
122 $morehtmlref .=
'<input type="hidden" name="action" value="classin">';
123 $morehtmlref .=
'<input type="hidden" name="token" value="'.newToken().
'">';
124 $morehtmlref .= $formproject->select_projects($object->socid, $object->fk_project,
'projectid', $maxlength, 0, 1, 0, 1, 0, 0,
'', 1);
125 $morehtmlref .=
'<input type="submit" class="button valignmiddle" value="'.$langs->trans(
"Modify").
'">';
126 $morehtmlref .=
'</form>';
128 $morehtmlref .= $form->form_project($_SERVER[
'PHP_SELF'].
'?id='.$object->id, !empty($object->socid) ? $object->socid : 0, $object->fk_project,
'none', 0, 0, 0, 1,
'',
'maxwidth300');
131 if (!empty($object->fk_project)) {
133 $proj->fetch($object->fk_project);
134 $morehtmlref .=
': '.$proj->getNomUrl();
140 $morehtmlref .=
'</div>';
143 dol_banner_tab($object,
'ref', $linkback, 1,
'ref',
'ref', $morehtmlref);
146 print
'<div class="fichecenter">';
147 print
'<div class="underbanner clearboth"></div>';
150 $cssclass =
"titlefield";
151 include DOL_DOCUMENT_ROOT.
'/core/tpl/notes.tpl.php';
if(!defined('NOREQUIRESOC')) if(!defined( 'NOREQUIRETRAN')) if(!defined('NOTOKENRENEWAL')) if(!defined( 'NOREQUIREMENU')) if(!defined('NOREQUIREHTML')) if(!defined( 'NOREQUIREAJAX')) llxHeader()
Empty header.
Class to manage projects.
Class for RecruitmentJobPosition.
dol_banner_tab($object, $paramid, $morehtml='', $shownav=1, $fieldid='rowid', $fieldref='ref', $morehtmlref='', $moreparam='', $nodbprefix=0, $morehtmlleft='', $morehtmlstatus='', $onlybanner=0, $morehtmlright='')
Show tab footer of a card.
dol_get_fiche_head($links=array(), $active='', $title='', $notab=0, $picto='', $pictoisfullpath=0, $morehtmlright='', $morecss='', $limittoshow=0, $moretabssuffix='', $dragdropfile=0)
Show tabs of a record.
dol_get_fiche_end($notab=0)
Return tab footer of a card.
GETPOST($paramname, $check='alphanohtml', $method=0, $filter=null, $options=null, $noreplace=0)
Return value of a param into GET or POST supervariable.
setEventMessages($mesg, $mesgs, $style='mesgs', $messagekey='', $noduplicate=0)
Set event messages in dol_events session object.
recruitmentjobpositionPrepareHead($object)
Prepare array of tabs for RecruitmentJobPosition.
restrictedArea(User $user, $features, $object=0, $tableandshare='', $feature2='', $dbt_keyfield='fk_soc', $dbt_select='rowid', $isdraft=0, $mode=0)
Check permissions of a user to show a page and an object.