mirror of
https://github.com/Dolibarr/dolibarr.git
synced 2025-02-20 13:46:52 +01:00
Fix regression in button
This commit is contained in:
parent
b1e826da15
commit
1a8af3509e
|
|
@ -1911,12 +1911,12 @@ if ($action == 'create' || $action == 'adduserldap') {
|
|||
);
|
||||
if ($user->id <> $id && $candisableuser && $object->statut == 0 &&
|
||||
((empty($conf->multicompany->enabled) && $object->entity == $user->entity) || !$user->entity || ($object->entity == $conf->entity) || ($conf->global->MULTICOMPANY_TRANSVERSE_MODE && $conf->entity == 1))) {
|
||||
print dolGetButtonAction($langs->trans('Reactivate'), '', 'default', $_SERVER['PHP_SELF'] . '?id=' . $object->id . '&action=enable&token='.newToken().$langs->trans("Reactivate"), '', true, $params);
|
||||
print dolGetButtonAction($langs->trans('Reactivate'), '', 'default', $_SERVER['PHP_SELF'] . '?id=' . $object->id . '&action=enable&token='.newToken(), '', true, $params);
|
||||
}
|
||||
// Disable user
|
||||
if ($user->id <> $id && $candisableuser && $object->statut == 1 &&
|
||||
((empty($conf->multicompany->enabled) && $object->entity == $user->entity) || !$user->entity || ($object->entity == $conf->entity) || ($conf->global->MULTICOMPANY_TRANSVERSE_MODE && $conf->entity == 1))) {
|
||||
print dolGetButtonAction($langs->trans('DisableUser'), '', 'default', $_SERVER['PHP_SELF'] . '?id=' . $object->id . '&action=disable&token='.newToken().$langs->trans("DisableUser"), '', true, $params);
|
||||
print dolGetButtonAction($langs->trans('DisableUser'), '', 'default', $_SERVER['PHP_SELF'] . '?id=' . $object->id . '&action=disable&token='.newToken(), '', true, $params);
|
||||
} else {
|
||||
if ($user->id == $id) {
|
||||
$params['attr']['title'] = $langs->trans('CantDisableYourself');
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user