From 040c675de64a813a54bd45d2587bc8c6919d03ac Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Tue, 7 Aug 2012 14:54:56 +0200 Subject: [PATCH] Fix: Do not overwrite global $user information --- htdocs/projet/tasks/time.php | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/htdocs/projet/tasks/time.php b/htdocs/projet/tasks/time.php index 2e0d8b66984..68d2ced3d7e 100644 --- a/htdocs/projet/tasks/time.php +++ b/htdocs/projet/tasks/time.php @@ -170,6 +170,7 @@ if (! empty($project_ref) && ! empty($withproject)) llxHeader("",$langs->trans("Task")); $form = new Form($db); +$userstatic = new User($db); if ($id > 0 || ! empty($ref)) { @@ -403,17 +404,17 @@ if ($id > 0 || ! empty($ref)) print ''; // User - $user->id = $task_time->fk_user; print ''; if ($_GET['action'] == 'editline' && $_GET['lineid'] == $task_time->rowid) { - print $form->select_users($user->id,'userid_line'); + print $form->select_users($task_time->fk_user,'userid_line'); } else { - $user->nom = $task_time->name; - $user->prenom = $task_time->firstname; - print $user->getNomUrl(1); + $userstatic->id = $task_time->fk_user; + $userstatic->nom = $task_time->name; + $userstatic->prenom = $task_time->firstname; + print $userstatic->getNomUrl(1); } print '';