From 70af9b548f453bf4f0650a5d83c149460fc01b45 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fr=C3=A9d=C3=A9ric=20FRANCE?= Date: Thu, 9 Jun 2022 12:04:35 +0200 Subject: [PATCH 1/3] avoid extra space after idprof --- htdocs/societe/card.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/htdocs/societe/card.php b/htdocs/societe/card.php index ca4a8a54775..311eea6bc8e 100644 --- a/htdocs/societe/card.php +++ b/htdocs/societe/card.php @@ -2672,7 +2672,9 @@ if (is_object($objcanvas) && $objcanvas->displayCanvasExists($action)) { print dol_print_profids($object->$key, 'ProfId'.$i, $object->country_code, 1); if ($object->$key) { if ($object->id_prof_check($i, $object) > 0) { - print '   '.$object->id_prof_url($i, $object); + if (!empty($object->id_prof_url($i, $object))) { + print '   '.$object->id_prof_url($i, $object); + } } else { print ' ('.$langs->trans("ErrorWrongValue").')'; } From 8a48cd5989e87c9578ccdaaadccbb6fb07367ade Mon Sep 17 00:00:00 2001 From: NASDAMI Quatadah Date: Thu, 9 Jun 2022 12:05:23 +0200 Subject: [PATCH 2/3] Fixing bug --- htdocs/projet/tasks/time.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/htdocs/projet/tasks/time.php b/htdocs/projet/tasks/time.php index ef8ac6aa9df..0fb54aa1a48 100644 --- a/htdocs/projet/tasks/time.php +++ b/htdocs/projet/tasks/time.php @@ -246,7 +246,8 @@ if (($action == 'updateline' || $action == 'updatesplitline') && !$cancel && $us if (!$error) { if (GETPOST('taskid', 'int') != $id) { // GETPOST('taskid') is id of new task - $id = GETPOST('taskid', 'int'); + $id_temp = GETPOST('taskid', 'int'); // should not overwrite $id + $object->fetchTimeSpent(GETPOST('lineid', 'int')); @@ -255,7 +256,7 @@ if (($action == 'updateline' || $action == 'updatesplitline') && !$cancel && $us $result = $object->delTimeSpent($user); } - $object->fetch($id, $ref); + $object->fetch($id_temp, $ref); $object->timespent_note = GETPOST("timespent_note_line", 'alpha'); $object->timespent_old_duration = GETPOST("old_duration"); From fb86cea3fcb5b4024e85f6c41ecbf242398d2c90 Mon Sep 17 00:00:00 2001 From: stickler-ci Date: Thu, 9 Jun 2022 10:09:49 +0000 Subject: [PATCH 3/3] Fixing style errors. --- htdocs/projet/tasks/time.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/htdocs/projet/tasks/time.php b/htdocs/projet/tasks/time.php index 0fb54aa1a48..08d44ffcbd8 100644 --- a/htdocs/projet/tasks/time.php +++ b/htdocs/projet/tasks/time.php @@ -247,7 +247,7 @@ if (($action == 'updateline' || $action == 'updatesplitline') && !$cancel && $us if (!$error) { if (GETPOST('taskid', 'int') != $id) { // GETPOST('taskid') is id of new task $id_temp = GETPOST('taskid', 'int'); // should not overwrite $id - + $object->fetchTimeSpent(GETPOST('lineid', 'int'));