Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop
This commit is contained in:
commit
d395fac13b
@ -46,7 +46,7 @@ foreach ($linkedObjectBlock as $key => $objectlink) {
|
||||
?>
|
||||
<tr class="<?php echo $trclass; ?>">
|
||||
<td><?php echo $langs->trans("Contract"); ?></td>
|
||||
<td><?php echo $objectlink->getNomUrl(1); ?></td>
|
||||
<td class="nowraponall"><?php echo $objectlink->getNomUrl(1); ?></td>
|
||||
<td></td>
|
||||
<td class="center"><?php echo dol_print_date($objectlink->date_contrat, 'day'); ?></td>
|
||||
<td class="right"><?php
|
||||
|
||||
@ -1793,6 +1793,31 @@ function print_left_eldy_menu($db, $menu_array_before, $menu_array_after, &$tabM
|
||||
$newmenu->add("/user/list.php?mainmenu=hrm&leftmenu=hrm&mode=employee", $langs->trans("Employees"), 0, $user->rights->user->user->lire, '', $mainmenu, 'hrm', 0, '', '', '', img_picto('', 'user', 'class="pictofixedwidth"'));
|
||||
$newmenu->add("/user/card.php?mainmenu=hrm&leftmenu=hrm&action=create&employee=1", $langs->trans("NewEmployee"), 1, $user->rights->user->user->creer);
|
||||
$newmenu->add("/user/list.php?mainmenu=hrm&leftmenu=hrm&mode=employee&contextpage=employeelist", $langs->trans("List"), 1, $user->rights->user->user->lire);
|
||||
|
||||
$newmenu->add("/hrm/index.php?mainmenu=hrm&leftmenu=hrm_sm", $langs->trans("SkillsManagement"), 0, $user->rights->hrm->all->read, '', $mainmenu, 'hrm_sm', 0, '', '', '', img_picto('', 'user', 'class="pictofixedwidth"'));
|
||||
|
||||
if ($usemenuhider || empty($leftmenu) || $leftmenu == "hrm_sm") {
|
||||
// Skills
|
||||
$newmenu->add("/hrm/skill_list.php?mainmenu=hrm&leftmenu=hrm_sm", $langs->trans("Skills"), 1, $user->rights->hrm->all->read, '', $mainmenu, 'hrm_sm', 0, '', '', '', img_picto('', 'shapes', 'class="pictofixedwidth"'));
|
||||
//$newmenu->add("/hrm/skill_card.php?mainmenu=hrm&leftmenu=hrm_sm&action=create", $langs->trans("NewSkill"), 1, $user->rights->hrm->all->write);
|
||||
//$newmenu->add("/hrm/skill_list.php?mainmenu=hrm&leftmenu=hrm_sm", $langs->trans("List"), 1, $user->rights->hrm->all->read);
|
||||
|
||||
// Job (Description of work to do and skills required)
|
||||
$newmenu->add("/hrm/job_list.php?mainmenu=hrm&leftmenu=hrm_sm", $langs->trans("JobsPosition"), 1, $user->rights->hrm->all->read, '', $mainmenu, 'hrm_sm', 0, '', '', '', img_picto('', 'technic', 'class="pictofixedwidth"'));
|
||||
//$newmenu->add("/hrm/job_card.php?mainmenu=hrm&leftmenu=hrm_sm&action=create", $langs->transnoentities("NewObject", $langs->trans("Job")), 1, $user->rights->hrm->all->write);
|
||||
//$newmenu->add("/hrm/job_list.php?mainmenu=hrm&leftmenu=hrm_sm", $langs->trans("List"), 1, $user->rights->hrm->all->read);
|
||||
|
||||
// Position = Link job - user
|
||||
$newmenu->add("/hrm/position_list.php?mainmenu=hrm&leftmenu=hrm_sm", $langs->trans("EmployeePositions"), 1, $user->rights->hrm->all->read, '', $mainmenu, 'hrm_sm', 0, '', '', '', img_picto('', 'user-cog', 'class="pictofixedwidth"'));
|
||||
//$newmenu->add("/hrm/position.php?mainmenu=hrm&leftmenu=hrm_sm&action=create", $langs->transnoentities("NewObject", $langs->trans("Position")), 1, $user->rights->hrm->all->write);
|
||||
//$newmenu->add("/hrm/position_list.php?mainmenu=hrm&leftmenu=hrm_sm", $langs->trans("List"), 1, $user->rights->hrm->all->read);
|
||||
|
||||
// Evaluation
|
||||
$newmenu->add("/hrm/evaluation_list.php?mainmenu=hrm&leftmenu=hrm_sm", $langs->trans("Evalutions"), 1, $user->rights->hrm->evaluation->read, '', $mainmenu, 'hrm_sm', 0, '', '', '', img_picto('', 'user', 'class="pictofixedwidth"'));
|
||||
//$newmenu->add("/hrm/evaluation_card.php?mainmenu=hrm&leftmenu=hrm_sm&action=create", $langs->trans("NewEval"), 1, $user->rights->hrm->evaluation->write);
|
||||
//$newmenu->add("/hrm/evaluation_list.php?mainmenu=hrm&leftmenu=hrm_sm", $langs->trans("List"), 1, $user->rights->hrm->evaluation->read);
|
||||
$newmenu->add("/hrm/compare.php?mainmenu=hrm&leftmenu=hrm_sm", $langs->trans("SkillComparison"), 1, $user->rights->hrm->evaluation->read || $user->rights->hrm->compare->read);
|
||||
}
|
||||
}
|
||||
|
||||
// Leave/Holiday/Vacation module
|
||||
@ -1850,29 +1875,6 @@ function print_left_eldy_menu($db, $menu_array_before, $menu_array_after, &$tabM
|
||||
$newmenu->add("/projet/activity/perweek.php?leftmenu=tasks".($search_project_user ? '&search_project_user='.$search_project_user : ''), $langs->trans("NewTimeSpent"), 0, $user->rights->projet->lire, '', $mainmenu, 'timespent', 0, '', '', '', img_picto('', 'timespent', 'class="pictofixedwidth"'));
|
||||
}
|
||||
}
|
||||
|
||||
if (!empty($conf->hrm->enabled)) {
|
||||
// Skills
|
||||
$newmenu->add("/hrm/skill_list.php?mainmenu=hrm&leftmenu=hrm", $langs->trans("skill"), 0, $user->rights->hrm->all->read, '', $mainmenu, 'hrm', 0, '', '', '', img_picto('', 'shapes', 'class="pictofixedwidth"'));
|
||||
$newmenu->add("/hrm/skill_card.php?mainmenu=hrm&leftmenu=hrm&action=create", $langs->trans("NewSkill"), 1, $user->rights->hrm->all->write);
|
||||
$newmenu->add("/hrm/skill_list.php?mainmenu=hrm&leftmenu=hrm", $langs->trans("List"), 1, $user->rights->hrm->all->read);
|
||||
|
||||
// Job
|
||||
$newmenu->add("/hrm/job_list.php?mainmenu=hrm&leftmenu=hrm", $langs->trans("Job"), 0, $user->rights->hrm->all->read, '', $mainmenu, 'hrm', 0, '', '', '', img_picto('', 'technic', 'class="pictofixedwidth"'));
|
||||
$newmenu->add("/hrm/job_card.php?mainmenu=hrm&leftmenu=hrm&action=create", $langs->transnoentities("NewObject", $langs->trans("Job")), 1, $user->rights->hrm->all->write);
|
||||
$newmenu->add("/hrm/job_list.php?mainmenu=hrm&leftmenu=hrm", $langs->trans("List"), 1, $user->rights->hrm->all->read);
|
||||
|
||||
// Position
|
||||
$newmenu->add("/hrm/position_list.php?mainmenu=hrm&leftmenu=hrm", $langs->trans("Position"), 0, $user->rights->hrm->all->read, '', $mainmenu, 'hrm', 0, '', '', '', img_picto('', 'user-cog', 'class="pictofixedwidth"'));
|
||||
$newmenu->add("/hrm/position.php?mainmenu=hrm&leftmenu=hrm&action=create", $langs->transnoentities("NewObject", $langs->trans("Position")), 1, $user->rights->hrm->all->write);
|
||||
$newmenu->add("/hrm/position_list.php?mainmenu=hrm&leftmenu=hrm", $langs->trans("List"), 1, $user->rights->hrm->all->read);
|
||||
|
||||
// Evaluation
|
||||
$newmenu->add("/hrm/evaluation_list.php?mainmenu=hrm&leftmenu=hrm", $langs->trans("Eval"), 0, $user->rights->hrm->evaluation->read, '', $mainmenu, 'hrm', 0, '', '', '', img_picto('', 'user', 'class="pictofixedwidth"'));
|
||||
$newmenu->add("/hrm/evaluation_card.php?mainmenu=hrm&leftmenu=hrm&action=create", $langs->trans("NewEval"), 1, $user->rights->hrm->evaluation->write);
|
||||
$newmenu->add("/hrm/evaluation_list.php?mainmenu=hrm&leftmenu=hrm", $langs->trans("List"), 1, $user->rights->hrm->evaluation->read);
|
||||
$newmenu->add("/hrm/compare.php?mainmenu=hrm&leftmenu=hrm", $langs->trans("Compare"), 1, $user->rights->hrm->compare->read);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
@ -196,21 +196,21 @@ class modHRM extends DolibarrModules
|
||||
$r = 0;
|
||||
|
||||
// Skill / Job / Position
|
||||
$this->rights[$r][0] = 4010; // Permission id (must not be already used)
|
||||
$this->rights[$r][0] = 4001; // Permission id (must not be already used)
|
||||
$this->rights[$r][1] = 'Read skill/job/position'; // Permission label
|
||||
$this->rights[$r][3] = 0; // Permission by default for new user (0/1)
|
||||
$this->rights[$r][4] = 'all';
|
||||
$this->rights[$r][5] = 'read'; // In php code, permission will be checked by test if ($user->rights->hrm->all->read)
|
||||
$r++;
|
||||
|
||||
$this->rights[$r][0] = 4011; // Permission id (must not be already used)
|
||||
$this->rights[$r][0] = 4002; // Permission id (must not be already used)
|
||||
$this->rights[$r][1] = 'Create/modify skill/job/position'; // Permission label
|
||||
$this->rights[$r][3] = 0; // Permission by default for new user (0/1)
|
||||
$this->rights[$r][4] = 'all';
|
||||
$this->rights[$r][5] = 'write'; // In php code, permission will be checked by test if ($user->rights->hrm->all->write)
|
||||
$r++;
|
||||
|
||||
$this->rights[$r][0] = 4012; // Permission id (must not be already used)
|
||||
$this->rights[$r][0] = 4003; // Permission id (must not be already used)
|
||||
$this->rights[$r][1] = 'Delete skill/job/position'; // Permission label
|
||||
$this->rights[$r][3] = 0; // Permission by default for new user (0/1)
|
||||
$this->rights[$r][4] = 'all';
|
||||
@ -226,7 +226,7 @@ class modHRM extends DolibarrModules
|
||||
$r++;
|
||||
|
||||
$this->rights[$r][0] = 4021; // Permission id (must not be already used)
|
||||
$this->rights[$r][1] = 'Create/modify your own evaluation'; // Permission label
|
||||
$this->rights[$r][1] = 'Create/modify your evaluation'; // Permission label
|
||||
$this->rights[$r][3] = 0; // Permission by default for new user (0/1)
|
||||
$this->rights[$r][4] = 'evaluation';
|
||||
$this->rights[$r][5] = 'write'; // In php code, permission will be checked by test if ($user->rights->hrm->evaluation->write)
|
||||
@ -240,7 +240,7 @@ class modHRM extends DolibarrModules
|
||||
$r++;
|
||||
|
||||
$this->rights[$r][0] = 4023; // Permission id (must not be already used)
|
||||
$this->rights[$r][1] = 'Delete all evaluations'; // Permission label
|
||||
$this->rights[$r][1] = 'Delete evaluations'; // Permission label
|
||||
$this->rights[$r][3] = 0; // Permission by default for new user (0/1)
|
||||
$this->rights[$r][4] = 'evaluation';
|
||||
$this->rights[$r][5] = 'delete'; // In php code, permission will be checked by test if ($user->rights->hrm->evaluation->delete)
|
||||
|
||||
@ -936,7 +936,7 @@ if ($resql) {
|
||||
$moreforfilter .= '<div class="divsearchfield">';
|
||||
$tmptitle = $langs->trans('IncludingProductWithTag');
|
||||
$cate_arbo = $form->select_all_categories(Categorie::TYPE_PRODUCT, null, 'parent', null, null, 1);
|
||||
$moreforfilter .= img_picto($tmptitle, 'category', 'class="pictofixedwidth"').$form->selectarray('search_product_category', $cate_arbo, $search_product_category, $tmptitle, 0, 0, '', 0, 0, 0, 0, 'maxwidth300', 1);
|
||||
$moreforfilter .= img_picto($tmptitle, 'category', 'class="pictofixedwidth"').$form->selectarray('search_product_category', $cate_arbo, $search_product_category, $tmptitle, 0, 0, '', 0, 0, 0, 0, 'maxwidth300 widthcentpercentminusx', 1);
|
||||
$moreforfilter .= '</div>';
|
||||
}
|
||||
|
||||
@ -1367,11 +1367,11 @@ if ($resql) {
|
||||
|
||||
print '<tr class="oddeven">';
|
||||
if (!empty($arrayfields['f.ref']['checked'])) {
|
||||
print '<td class="nowrap">';
|
||||
print '<td class="nowraponall">';
|
||||
|
||||
print '<table class="nobordernopadding"><tr class="nocellnopadd">';
|
||||
// Picto + Ref
|
||||
print '<td class="nobordernopadding nowrap">';
|
||||
print '<td class="nobordernopadding nowraponall">';
|
||||
print $facturestatic->getNomUrl(1, '', 0, 0, '', 0, -1, 1);
|
||||
|
||||
$filename = dol_sanitizeFileName($obj->ref);
|
||||
|
||||
@ -36,21 +36,25 @@
|
||||
require_once '../main.inc.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/functions.lib.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/functions2.lib.php';
|
||||
|
||||
ini_set('display_errors', 1);
|
||||
|
||||
require_once DOL_DOCUMENT_ROOT . '/hrm/class/skill.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT . '/hrm/class/job.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT . '/hrm/class/evaluation.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT . '/hrm/class/position.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT . '/hrm/lib/hrm.lib.php';
|
||||
|
||||
$permissiontoread = $user->rights->hrm->compare->read;
|
||||
$permissiontoread = $user->rights->hrm->evaluation->read || $user->rights->hrm->compare->read;
|
||||
$permissiontoadd = 0;
|
||||
if (empty($conf->hrm->enabled)) accessforbidden();
|
||||
if (!$permissiontoread || ($action === 'create' && !$permissiontoadd)) accessforbidden();
|
||||
|
||||
$langs->load('hrm');
|
||||
|
||||
|
||||
|
||||
/*
|
||||
* View
|
||||
*/
|
||||
|
||||
$css = array();
|
||||
$css[] = '/hrm/css/style.css';
|
||||
llxHeader('', $langs->trans('SkillComparison'), '', '', 0, 0, '', $css);
|
||||
|
||||
@ -153,7 +153,7 @@ if (!empty($conf->holiday->enabled)) {
|
||||
print '<table class="noborder nohover centpercent">';
|
||||
print '<tr class="liste_titre"><th colspan="3">'.$langs->trans("Holidays").'</th></tr>';
|
||||
print '<tr class="oddeven">';
|
||||
print '<td colspan="3">';
|
||||
print '<td>';
|
||||
|
||||
$out = '';
|
||||
$nb_holiday = 0;
|
||||
@ -163,8 +163,9 @@ if (!empty($conf->holiday->enabled)) {
|
||||
$nb_holiday += $nb_type;
|
||||
$out .= ' - '.($langs->trans($val['code']) != $val['code'] ? $langs->trans($val['code']) : $val['label']).': <strong>'.($nb_type ? price2num($nb_type) : 0).'</strong><br>';
|
||||
}
|
||||
print $langs->trans('SoldeCPUser', round($nb_holiday, 5)).'<br>';
|
||||
print $out;
|
||||
$balancetoshow = $langs->trans('SoldeCPUser', '{s1}');
|
||||
print '<div class="valignmiddle div-balanceofleave">'.str_replace('{s1}', img_picto('', 'holiday', 'class="paddingleft pictofixedwidth"').'<span class="balanceofleave valignmiddle'.($nb_holiday > 0 ? ' amountpaymentcomplete' : ($nb_holiday < 0 ? ' amountremaintopay' : ' amountpaymentneutral')).'">'.round($nb_holiday, 5).'</span>', $balancetoshow).'</div>';
|
||||
print '<span class="opacitymedium">'.$out.'</span>';
|
||||
|
||||
print '</td>';
|
||||
print '</tr>';
|
||||
|
||||
@ -300,6 +300,8 @@ CREATE TABLE llx_hrm_job_user(
|
||||
fk_user_modif integer
|
||||
) ENGINE=innodb;
|
||||
|
||||
ALTER TABLE llx_hrm_job_user ADD COLUMN abort_comment varchar(255);
|
||||
|
||||
ALTER TABLE llx_hrm_job_user ADD INDEX idx_hrm_job_user_rowid (rowid);
|
||||
-- ALTER TABLE llx_hrm_job_user ADD INDEX idx_hrm_job_user_ref (ref);
|
||||
|
||||
|
||||
@ -27,7 +27,7 @@ DescCP=Description
|
||||
SendRequestCP=Create leave request
|
||||
DelayToRequestCP=Leave requests must be made at least <b>%s day(s)</b> before them.
|
||||
MenuConfCP=Balance of leave
|
||||
SoldeCPUser=Leave balance is <b>%s</b> days.
|
||||
SoldeCPUser=Leave balance (in days) <b>%s</b>
|
||||
ErrorEndDateCP=You must select an end date greater than the start date.
|
||||
ErrorSQLCreateCP=An SQL error occurred during the creation:
|
||||
ErrorIDFicheCP=An error has occurred, the leave request does not exist.
|
||||
|
||||
@ -20,13 +20,14 @@ Employee=Employee
|
||||
NewEmployee=New employee
|
||||
ListOfEmployees=List of employees
|
||||
HrmSetup=HRM module setup
|
||||
SkillsManagement=Skills management
|
||||
HRM_MAXRANK=Maximum rank for a skill
|
||||
HRM_DEFAULT_SKILL_DESCRIPTION=Default description of ranks when skill is created
|
||||
deplacement=Shift
|
||||
DateEval=Evaluation date
|
||||
JobCard=Job card
|
||||
Job=Job
|
||||
Jobs=Jobs
|
||||
JobPosition=Job
|
||||
JobsPosition=Jobs
|
||||
NewSkill=New Skill
|
||||
SkillType=Skill type
|
||||
Skilldets=List of ranks for this skill
|
||||
@ -47,9 +48,8 @@ ConfirmValidateEvaluation=Are you sure you want to validate this evaluation with
|
||||
EvaluationCard=Evaluation card
|
||||
RequiredRank=Required rank for this job
|
||||
EmployeeRank=Employee rank for this skill
|
||||
Position=Position
|
||||
Positions=Positions
|
||||
PositionCard=Position card
|
||||
EmployeePosition=Employee position
|
||||
EmployeePositions=Employee positions
|
||||
EmployeesInThisPosition=Employees in this position
|
||||
group1ToCompare=Usergroup to analyze
|
||||
group2ToCompare=Second usergroup for comparison
|
||||
|
||||
@ -751,6 +751,9 @@ $url = DOL_URL_ROOT.'/projet/card.php?action=create';
|
||||
if (!empty($socid)) {
|
||||
$url .= '&socid='.$socid;
|
||||
}
|
||||
if ($search_usage_event_organization == 1) {
|
||||
$url .= '&usage_organize_event=1';
|
||||
}
|
||||
$newcardbutton = dolGetButtonTitle($langs->trans('NewProject'), '', 'fa fa-plus-circle', $url, '', $user->rights->projet->creer);
|
||||
|
||||
print '<form method="POST" id="searchFormList" action="'.$_SERVER["PHP_SELF"].'">';
|
||||
|
||||
@ -726,7 +726,7 @@ if (!empty($arrayfields['u.tms']['checked'])) {
|
||||
if (!empty($arrayfields['u.statut']['checked'])) {
|
||||
// Status
|
||||
print '<td class="liste_titre center">';
|
||||
print $form->selectarray('search_statut', array('-1'=>'', '0'=>$langs->trans('Disabled'), '1'=>$langs->trans('Enabled')), $search_statut);
|
||||
print $form->selectarray('search_statut', array('-1'=>'', '0'=>$langs->trans('Disabled'), '1'=>$langs->trans('Enabled')), $search_statut, 0, 0, 0, '', 0, 0, 0, '', 'minwidth50');
|
||||
print '</td>';
|
||||
}
|
||||
// Action column
|
||||
|
||||
Loading…
Reference in New Issue
Block a user