wip: add read employee and write employee

This commit is contained in:
steve 2022-02-28 15:58:23 +01:00
parent 99ddef0530
commit 08fa2dfadd
2 changed files with 18 additions and 0 deletions

View File

@ -249,6 +249,22 @@ class modHRM extends DolibarrModules
$this->rights[$r][4] = 'compare_advance';
$this->rights[$r][5] = 'read'; // In php code, permission will be checked by test if ($user->rights->hrm->compare_advance->read)
$r++;
// Read employee
$this->rights[$r][0] = 4031; // Permission id (must not be already used)
$this->rights[$r][1] = 'Read employee'; // Permission label
$this->rights[$r][3] = 0; // Permission by default for new user (0/1)
$this->rights[$r][4] = 'read_employee';
$this->rights[$r][5] = 'read'; // In php code, permission will be checked by test if ($user->rights->hrm->compare_advance->read)
$r++;
// Write employee
$this->rights[$r][0] = 4032; // Permission id (must not be already used)
$this->rights[$r][1] = 'Write employee'; // Permission label
$this->rights[$r][3] = 0; // Permission by default for new user (0/1)
$this->rights[$r][4] = 'write_employee';
$this->rights[$r][5] = 'write'; // In php code, permission will be checked by test if ($user->rights->hrm->compare_advance->read)
$r++;
}
/**

View File

@ -969,6 +969,8 @@ Permission4021=Create/modify your evaluation
Permission4022=Validate evaluation
Permission4023=Delete evaluation
Permission4030=See comparison menu
Permission4031=Read employee
Permission4032=Write employee
Permission10001=Read website content
Permission10002=Create/modify website content (html and javascript content)
Permission10003=Create/modify website content (dynamic php code). Dangerous, must be reserved to restricted developers.