From 59c98990354ff17d695b09e30c4938fcfc2f67a2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Benjamin=20Fali=C3=A8re?= Date: Tue, 21 Mar 2023 17:09:33 +0100 Subject: [PATCH 1/4] NEW add link to thirdparty tickets history --- htdocs/ticket/card.php | 1 + 1 file changed, 1 insertion(+) diff --git a/htdocs/ticket/card.php b/htdocs/ticket/card.php index 8e2114f9bae..5e44045f88c 100755 --- a/htdocs/ticket/card.php +++ b/htdocs/ticket/card.php @@ -961,6 +961,7 @@ if ($action == 'create' || $action == 'presend') { $morehtmlref .= ''.img_edit($langs->transnoentitiesnoconv('SetThirdParty'), 0).' '; } $morehtmlref .= $form->form_thirdparty($url_page_current.'?track_id='.$object->track_id, $object->socid, $action == 'editcustomer' ? 'editcustomer' : 'none', '', 1, 0, 0, array(), 1); + $morehtmlref .= ' - '.img_picto($langs->trans("Tickets"), 'ticket', 'class="pictofixedwidth"').' '.$langs->trans("TicketHistory").''; } // Project From f28e2f525c0b0230e46dafe3f335db1c05b17612 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Benjamin=20Fali=C3=A8re?= Date: Tue, 21 Mar 2023 17:14:15 +0100 Subject: [PATCH 2/4] Added my name --- htdocs/ticket/card.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/htdocs/ticket/card.php b/htdocs/ticket/card.php index 5e44045f88c..5c5e6525a6f 100755 --- a/htdocs/ticket/card.php +++ b/htdocs/ticket/card.php @@ -5,7 +5,8 @@ * Copyright (C) 2021 Frédéric France * Copyright (C) 2021 Alexandre Spangaro * Copyright (C) 2022 Charlene Benke - * + * Copyright (C) 2023 Benjamin Falière + * * 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 * the Free Software Foundation; either version 3 of the License, or From de18ca511f189aad4e08ffba40b9773b48232ebe Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Benjamin=20Fali=C3=A8re?= Date: Tue, 21 Mar 2023 17:27:14 +0100 Subject: [PATCH 3/4] Add non empty socid condition --- htdocs/ticket/card.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/htdocs/ticket/card.php b/htdocs/ticket/card.php index 5c5e6525a6f..940cd869da3 100755 --- a/htdocs/ticket/card.php +++ b/htdocs/ticket/card.php @@ -962,7 +962,9 @@ if ($action == 'create' || $action == 'presend') { $morehtmlref .= ''.img_edit($langs->transnoentitiesnoconv('SetThirdParty'), 0).' '; } $morehtmlref .= $form->form_thirdparty($url_page_current.'?track_id='.$object->track_id, $object->socid, $action == 'editcustomer' ? 'editcustomer' : 'none', '', 1, 0, 0, array(), 1); - $morehtmlref .= ' - '.img_picto($langs->trans("Tickets"), 'ticket', 'class="pictofixedwidth"').' '.$langs->trans("TicketHistory").''; + if (!empty($object->socid)) { + $morehtmlref .= ' - '.img_picto($langs->trans("Tickets"), 'ticket', 'class="pictofixedwidth"').' '.$langs->trans("TicketHistory").''; + } } // Project From fe375de2209515dada81316c3018de899379cf3a Mon Sep 17 00:00:00 2001 From: stickler-ci Date: Tue, 21 Mar 2023 16:56:07 +0000 Subject: [PATCH 4/4] Fixing style errors. --- htdocs/ticket/card.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/htdocs/ticket/card.php b/htdocs/ticket/card.php index 940cd869da3..08ffcc5cbb5 100755 --- a/htdocs/ticket/card.php +++ b/htdocs/ticket/card.php @@ -6,7 +6,7 @@ * Copyright (C) 2021 Alexandre Spangaro * Copyright (C) 2022 Charlene Benke * Copyright (C) 2023 Benjamin Falière - * + * * 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 * the Free Software Foundation; either version 3 of the License, or