diff --git a/agent/post/recurring_ticket.php b/agent/post/recurring_ticket.php
index 78589b190..115b663ec 100644
--- a/agent/post/recurring_ticket.php
+++ b/agent/post/recurring_ticket.php
@@ -190,7 +190,9 @@ if (isset($_POST['bulk_force_recurring_tickets'])) {
if (!empty($config_smtp_provider) && $config_ticket_client_general_notifications == 1 && filter_var($contact_email, FILTER_VALIDATE_EMAIL)) {
$email_subject = "Ticket Created - [$ticket_prefix$ticket_number] - $ticket_subject (scheduled)";
- $email_body = "##- Please type your reply above this line -##
Hello $contact_name,
A ticket regarding \"$ticket_subject\" has been automatically created for you.
--------------------------------
$ticket_details--------------------------------
Ticket: $ticket_prefix$ticket_number
Subject: $ticket_subject
Status: Open
Portal: https://$config_base_url/client/ticket.php?id=$id
--
$company_name - Support
$config_ticket_from_email
$company_phone";
+ // SLA response commitment for this client + priority, empty when no SLA applies
+ $sla_notice = escapeSql(getTicketSlaEmailNotice($id, $company_phone));
+ $email_body = "##- Please type your reply above this line -##
Hello $contact_name,
A ticket regarding \"$ticket_subject\" has been automatically created for you.
--------------------------------
$ticket_details--------------------------------
Ticket: $ticket_prefix$ticket_number
Subject: $ticket_subject
Status: Open
Portal: https://$config_base_url/client/ticket.php?id=$id$sla_notice
--
$company_name - Support
$config_ticket_from_email
$company_phone";
$email = [
'from' => $config_ticket_from_email,
@@ -337,7 +339,9 @@ if (isset($_GET['force_recurring_ticket'])) {
if (!empty($config_smtp_provider) && $config_ticket_client_general_notifications == 1 && filter_var($contact_email, FILTER_VALIDATE_EMAIL)) {
$email_subject = "Ticket created - [$ticket_prefix$ticket_number] - $ticket_subject (scheduled)";
- $email_body = "##- Please type your reply above this line -##
Hello $contact_name,
A ticket regarding \"$ticket_subject\" has been automatically created for you.
--------------------------------
$ticket_details--------------------------------
Ticket: $ticket_prefix$ticket_number
Subject: $ticket_subject
Status: Open
Portal: https://$config_base_url/client/ticket.php?id=$id
--
$company_name - Support
$config_ticket_from_email
$company_phone";
+ // SLA response commitment for this client + priority, empty when no SLA applies
+ $sla_notice = escapeSql(getTicketSlaEmailNotice($id, $company_phone));
+ $email_body = "##- Please type your reply above this line -##
Hello $contact_name,
A ticket regarding \"$ticket_subject\" has been automatically created for you.
--------------------------------
$ticket_details--------------------------------
Ticket: $ticket_prefix$ticket_number
Subject: $ticket_subject
Status: Open
Portal: https://$config_base_url/client/ticket.php?id=$id$sla_notice
--
$company_name - Support
$config_ticket_from_email
$company_phone";
$email = [
'from' => $config_ticket_from_email,
diff --git a/agent/post/ticket.php b/agent/post/ticket.php
index 8cc594e00..5bad5f6f6 100644
--- a/agent/post/ticket.php
+++ b/agent/post/ticket.php
@@ -140,7 +140,9 @@ if (isset($_POST['add_ticket'])) {
// EMAILING
$subject = "Ticket Created [$ticket_prefix$ticket_number] - $ticket_subject";
- $body = "##- Please type your reply above this line -##
Hello $contact_name,
A ticket regarding \"$ticket_subject\" has been created for you.
--------------------------------
$ticket_details--------------------------------
Ticket: $ticket_prefix$ticket_number
Subject: $ticket_subject
Status: Open
Portal: View ticket
--
$company_name - Support
$config_ticket_from_email
$company_phone";
+ // SLA response commitment for this client + priority, empty when no SLA applies
+ $sla_notice = escapeSql(getTicketSlaEmailNotice($ticket_id, $company_phone));
+ $body = "##- Please type your reply above this line -##
Hello $contact_name,
A ticket regarding \"$ticket_subject\" has been created for you.
--------------------------------
$ticket_details--------------------------------
Ticket: $ticket_prefix$ticket_number
Subject: $ticket_subject
Status: Open
Portal: View ticket$sla_notice
--
$company_name - Support
$config_ticket_from_email
$company_phone";
// Verify contact email is valid
if (filter_var($contact_email, FILTER_VALIDATE_EMAIL)) {
@@ -315,7 +317,9 @@ if (isset($_POST['edit_ticket'])) {
$data = []; // Queue array
$subject = "Ticket Created - [$ticket_prefix$ticket_number] - $ticket_subject";
- $body = "##- Please type your reply above this line -##
Hello $contact_name,
A ticket regarding \"$ticket_subject\" has been created for you.
--------------------------------
$ticket_details--------------------------------
Ticket: $ticket_prefix$ticket_number
Subject: $ticket_subject
Status: $ticket_status
Portal: View ticket
--
$company_name - Support
$config_ticket_from_email
$company_phone";
+ // SLA response commitment for this client + priority, empty when no SLA applies
+ $sla_notice = escapeSql(getTicketSlaEmailNotice($ticket_id, $company_phone));
+ $body = "##- Please type your reply above this line -##
Hello $contact_name,
A ticket regarding \"$ticket_subject\" has been created for you.
--------------------------------
$ticket_details--------------------------------
Ticket: $ticket_prefix$ticket_number
Subject: $ticket_subject
Status: $ticket_status
Portal: View ticket$sla_notice
--
$company_name - Support
$config_ticket_from_email
$company_phone";
// Only add contact to email queue if email is valid
@@ -511,7 +515,9 @@ if (isset($_POST['edit_ticket_contact'])) {
$data = []; // Queue array
$subject = "Ticket Created - [$ticket_prefix$ticket_number] - $ticket_subject";
- $body = "##- Please type your reply above this line -##
Hello $contact_name,
A ticket regarding \"$ticket_subject\" has been created for you.
--------------------------------
$ticket_details--------------------------------
Ticket: $ticket_prefix$ticket_number
Subject: $ticket_subject
Status: $ticket_status
Portal: View ticket
--
$company_name - Support
$config_ticket_from_email
$company_phone";
+ // SLA response commitment for this client + priority, empty when no SLA applies
+ $sla_notice = escapeSql(getTicketSlaEmailNotice($ticket_id, $company_phone));
+ $body = "##- Please type your reply above this line -##
Hello $contact_name,
A ticket regarding \"$ticket_subject\" has been created for you.
--------------------------------
$ticket_details--------------------------------
Ticket: $ticket_prefix$ticket_number
Subject: $ticket_subject
Status: $ticket_status
Portal: View ticket$sla_notice
--
$company_name - Support
$config_ticket_from_email
$company_phone";
$data[] = [
'from' => $config_ticket_from_email,
diff --git a/agent/ticket.php b/agent/ticket.php
index b823efb11..e412f0104 100644
--- a/agent/ticket.php
+++ b/agent/ticket.php
@@ -717,7 +717,7 @@ if (isset($_GET['ticket_id'])) {