More comments
This commit is contained in:
parent
042556a9cf
commit
e269aa83b5
@ -101,7 +101,7 @@ function check_user_password_dolibarr($usertotest,$passwordtotest,$entitytotest=
|
||||
|
||||
if ($passok && ! empty($obj->entity) && (! empty($conf->multicompany->enabled) && ! empty($conf->multicompany->transverse_mode)))
|
||||
{
|
||||
$ret=$mc->checkRight($obj->rowid, $entitytotest);
|
||||
$ret=$mc->checkRight($obj->rowid, $entitytotest); // The module multicompany check here user belong to at least one group into company. This is a bugged behaviour, so you must hack module to make thing working.
|
||||
if ($ret < 0) $passok=false;
|
||||
}
|
||||
|
||||
|
||||
@ -169,10 +169,11 @@ function check_user_password_ldap($usertotest,$passwordtotest,$entitytotest)
|
||||
dol_syslog("functions_ldap::check_user_password_ldap Sync user found id=".$user->id);
|
||||
// On verifie si le login a change et on met a jour les attributs dolibarr
|
||||
|
||||
if ($conf->multicompany->enabled) {
|
||||
if ($conf->multicompany->enabled)
|
||||
{
|
||||
global $mc;
|
||||
|
||||
$ret=$mc->checkRight($user->id, $entitytotest);
|
||||
$ret=$mc->checkRight($user->id, $entitytotest, $user); // The module multicompany check here user belong to at least one group into company. This is a bugged behaviour, so you must hack module to make thing working.
|
||||
if ($ret < 0)
|
||||
{
|
||||
dol_syslog("Failed to checkRight by module multicompany for user id = ".$user->id." into entity ".$entitytotest);
|
||||
|
||||
Loading…
Reference in New Issue
Block a user