From bb86be062cc702c608154e7ae490876462032ae1 Mon Sep 17 00:00:00 2001 From: Thomas Negre Date: Fri, 21 Jan 2022 09:44:22 +0100 Subject: [PATCH 1/2] NEW ticket module : add an option to enable default check notify tier at creation introduces new option TICKET_CHECK_NOTIFY_TIER_AT_CREATE --- htdocs/ticket/card.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) mode change 100644 => 100755 htdocs/ticket/card.php diff --git a/htdocs/ticket/card.php b/htdocs/ticket/card.php old mode 100644 new mode 100755 index cf665e8a470..68e95515bbf --- a/htdocs/ticket/card.php +++ b/htdocs/ticket/card.php @@ -742,7 +742,7 @@ if ($action == 'create' || $action == 'presend') { $formticket->withfromsocid = $socid ? $socid : $user->socid; $formticket->withfromcontactid = $contactid ? $contactid : ''; $formticket->withtitletopic = 1; - $formticket->withnotifytiersatcreate = ($notifyTiers ? 1 : 0); + $formticket->withnotifytiersatcreate = ($notifyTiers ? 1 : !empty($conf->global->TICKET_CHECK_NOTIFY_TIER_AT_CREATE) ? 1 : 0); $formticket->withusercreate = 0; $formticket->withref = 1; $formticket->fk_user_create = $user->id; From 255ac69a0df0c930588519b86be8f27ae7e8d6c6 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Sun, 23 Jan 2022 12:10:52 +0100 Subject: [PATCH 2/2] Update card.php --- 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 68e95515bbf..a15791f9d92 100755 --- a/htdocs/ticket/card.php +++ b/htdocs/ticket/card.php @@ -742,7 +742,7 @@ if ($action == 'create' || $action == 'presend') { $formticket->withfromsocid = $socid ? $socid : $user->socid; $formticket->withfromcontactid = $contactid ? $contactid : ''; $formticket->withtitletopic = 1; - $formticket->withnotifytiersatcreate = ($notifyTiers ? 1 : !empty($conf->global->TICKET_CHECK_NOTIFY_TIER_AT_CREATE) ? 1 : 0); + $formticket->withnotifytiersatcreate = ($notifyTiers ? 1 : (empty($conf->global->TICKET_CHECK_NOTIFY_THIRDPARTY_AT_CREATION) ? 0 : 1)); $formticket->withusercreate = 0; $formticket->withref = 1; $formticket->fk_user_create = $user->id;