diff --git a/htdocs/admin/agenda_other.php b/htdocs/admin/agenda_other.php index fab23f420a6..73480afa4c3 100644 --- a/htdocs/admin/agenda_other.php +++ b/htdocs/admin/agenda_other.php @@ -6,7 +6,7 @@ * Copyright (C) 2016 Charlie Benke * Copyright (C) 2017 Open-DSI * Copyright (C) 2024-2025 MDW - * Copyright (C) 2024-2025 Frédéric France + * Copyright (C) 2024-2026 Frédéric France * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -306,7 +306,7 @@ if (getDolGlobalInt('MAIN_FEATURES_LEVEL') >= 2) { if (getDolGlobalString('ACTION_EVENT_ADDON_PDF') == "$name") { print img_picto($langs->trans("Default"), 'on'); } else { - print 'scandir).'&label='.urlencode($module->name).'&type=action"" alt="'.$langs->trans("Default").'">'.img_picto($langs->trans("Disabled"), 'off').''; + print 'scandir).'&label='.urlencode($module->name).'&type=action"" alt="'.$langs->trans("Default").'">'.img_picto($langs->trans("Disabled"), 'off').''; } print ''; diff --git a/htdocs/dav/fileserver.php b/htdocs/dav/fileserver.php index 10f9c8bcf5f..99a15d6435f 100644 --- a/htdocs/dav/fileserver.php +++ b/htdocs/dav/fileserver.php @@ -2,7 +2,7 @@ /* Copyright (C) 2018 Destailleur Laurent * Copyright (C) 2019 Regis Houssin * Copyright (C) 2024 MDW - * Copyright (C) 2024 Frédéric France + * Copyright (C) 2024-2026 Frédéric France * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -156,7 +156,7 @@ $authBackend = new \Sabre\DAV\Auth\Backend\BasicCallBack( } // Check if user status is enabled - if ($user->statut != $user::STATUS_ENABLED) { + if ($user->status != $user::STATUS_ENABLED) { // Status is disabled dol_syslog("The user has been disabled."); return false; diff --git a/htdocs/fourn/facture/list.php b/htdocs/fourn/facture/list.php index 16a83e7278d..8cc00aaad21 100644 --- a/htdocs/fourn/facture/list.php +++ b/htdocs/fourn/facture/list.php @@ -1748,7 +1748,7 @@ while ($i < $imaxinloop) { $userstatic->lastname = $obj->lastname; $userstatic->firstname = $obj->firstname; $userstatic->email = $obj->user_email; - $userstatic->statut = $obj->user_statut; + $userstatic->statut = $obj->user_statut; // deprecated $userstatic->status = $obj->user_statut; $userstatic->entity = $obj->entity; $userstatic->photo = $obj->photo; diff --git a/htdocs/hrm/position_list.php b/htdocs/hrm/position_list.php index b80401ae1c7..0e094f1bd0c 100644 --- a/htdocs/hrm/position_list.php +++ b/htdocs/hrm/position_list.php @@ -4,7 +4,7 @@ * Copyright (C) 2021 Greg Rastklan * Copyright (C) 2021 Jean-Pascal BOUDET * Copyright (C) 2021 Grégory BLEMAND - * Copyright (C) 2024-2025 Frédéric France + * Copyright (C) 2024-2026 Frédéric France * Copyright (C) 2025 MDW * * This program is free software; you can redistribute it and/or modify @@ -685,8 +685,8 @@ while ($i < $imaxinloop) { $userstatic->firstname = $obj->firstname; $userstatic->lastname = $obj->lastname; $userstatic->email = $obj->email; - $userstatic->statut = $obj->statut; // deprecated - $userstatic->status = $obj->statut; + $userstatic->statut = (int) $obj->statut; // deprecated + $userstatic->status = (int) $obj->statut; $userstatic->login = $obj->login; $userstatic->photo = $obj->photo; diff --git a/htdocs/main.inc.php b/htdocs/main.inc.php index b3cc8a9eb9a..4ddb040c74b 100644 --- a/htdocs/main.inc.php +++ b/htdocs/main.inc.php @@ -1286,7 +1286,7 @@ if (!defined('NOLOGIN')) { } // Check if user is active - if ($user->statut < 1) { + if ($user->status < 1) { // If not active, we refuse the user $langs->loadLangs(array("errors", "other")); dol_syslog("Authentication KO as login is disabled", LOG_NOTICE); diff --git a/htdocs/webservices/server_user.php b/htdocs/webservices/server_user.php index 5304c175a2e..e7dbbea5350 100644 --- a/htdocs/webservices/server_user.php +++ b/htdocs/webservices/server_user.php @@ -1,7 +1,7 @@ * Copyright (C) 2024-2026 MDW - * Copyright (C) 2024-2025 Frédéric France + * Copyright (C) 2024-2026 Frédéric France * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -393,7 +393,8 @@ function getUser($authentication, $id, $ref = '', $ref_ext = '') 'fk_member' => $user->fk_member, 'datelastlogin' => dol_print_date($user->datelastlogin, 'dayhourrfc'), 'datepreviouslogin' => dol_print_date($user->datepreviouslogin, 'dayhourrfc'), - 'statut' => $user->statut, + 'statut' => (int) $user->statut, + 'status' => (int) $user->status, 'photo' => $user->photo, 'lang' => $user->lang, //'rights' => $user->rights,