improve emergency emailing (#7309)

* improve emergency emailing

1. set emergency CID name & number to the outbound CID name & number if emergency CID name & number are not set
2. remove duplicate item in email body
3. change the hardcoded email subject '911 Emergency Call' to be dynamically provided from the event. I do not like seeing the subject '911 Emergency Call' when it is an TEST call.

* improve emergency emailing

1. change the hardcoded email subject '911 Emergency Call' to be dynamically provided from the event. I do not like seeing the subject '911 Emergency Call' when it is an TEST call.
2. fix email template misspelling
3. improved email template with bold fonts
This commit is contained in:
chansizzle
2025-03-12 17:39:05 -06:00
committed by GitHub
parent 31a88e3a15
commit 95761621a6
2 changed files with 22 additions and 15 deletions

View File

@@ -510,15 +510,15 @@
$array['email_templates'][$x]['template_language'] = 'en-gb';
$array['email_templates'][$x]['template_category'] = 'plugin';
$array['email_templates'][$x]['template_subcategory'] = 'emergency';
$array['email_templates'][$x]['template_subject'] = '911 Emergency Call';
$array['email_templates'][$x]['template_subject'] = '\${event}';
$array['email_templates'][$x]['template_body'] = "<html>\n";
$array['email_templates'][$x]['template_body'] .= "<body>\n";
$array['email_templates'][$x]['template_body'] .= "From \${caller_id_name} <a href=\"tel:\${caller_id_number}\">\${caller_id_number}</a><br />\n";
$array['email_templates'][$x]['template_body'] .= "<strong>From:</strong> \${caller_id_name} <a href=\"tel:\${caller_id_number}\">\${caller_id_number}</a><br />\n";
$array['email_templates'][$x]['template_body'] .= "<br />\n";
$array['email_templates'][$x]['template_body'] .= "Emergency Name \${emergency_caller_id_name}<br />\n";
$array['email_templates'][$x]['template_body'] .= "Emergency Name \${emergency_caller_id_number}<br />\n";
$array['email_templates'][$x]['template_body'] .= "Received \${message_date}<br />\n";
$array['email_templates'][$x]['template_body'] .= "Event \${event}<br />\n";
$array['email_templates'][$x]['template_body'] .= "<strong>Emergency Name:</strong> \${emergency_caller_id_name}<br />\n";
$array['email_templates'][$x]['template_body'] .= "<strong>Emergency Number:</strong> \${emergency_caller_id_number}<br />\n";
$array['email_templates'][$x]['template_body'] .= "<strong>Received:</strong> \${message_date}<br />\n";
$array['email_templates'][$x]['template_body'] .= "<strong>Event:</strong> \${event}<br />\n";
$array['email_templates'][$x]['template_body'] .= "</body>\n";
$array['email_templates'][$x]['template_body'] .= "</html>\n";
$array['email_templates'][$x]['template_type'] = 'html';
@@ -530,15 +530,15 @@
$array['email_templates'][$x]['template_language'] = 'en-us';
$array['email_templates'][$x]['template_category'] = 'plugin';
$array['email_templates'][$x]['template_subcategory'] = 'emergency';
$array['email_templates'][$x]['template_subject'] = '911 Emergency Call';
$array['email_templates'][$x]['template_subject'] = '\${event}';
$array['email_templates'][$x]['template_body'] = "<html>\n";
$array['email_templates'][$x]['template_body'] .= "<body>\n";
$array['email_templates'][$x]['template_body'] .= "From \${caller_id_name} <a href=\"tel:\${caller_id_number}\">\${caller_id_number}</a><br />\n";
$array['email_templates'][$x]['template_body'] .= "<strong>From:</strong> \${caller_id_name} <a href=\"tel:\${caller_id_number}\">\${caller_id_number}</a><br />\n";
$array['email_templates'][$x]['template_body'] .= "<br />\n";
$array['email_templates'][$x]['template_body'] .= "Emergency Name \${emergency_caller_id_name}<br />\n";
$array['email_templates'][$x]['template_body'] .= "Emergency Name \${emergency_caller_id_number}<br />\n";
$array['email_templates'][$x]['template_body'] .= "Received \${message_date}<br />\n";
$array['email_templates'][$x]['template_body'] .= "Event \${event}<br />\n";
$array['email_templates'][$x]['template_body'] .= "<strong>Emergency Name:</strong> \${emergency_caller_id_name}<br />\n";
$array['email_templates'][$x]['template_body'] .= "<strong>Emergency Number:</strong> \${emergency_caller_id_number}<br />\n";
$array['email_templates'][$x]['template_body'] .= "<strong>Received:</strong> \${message_date}<br />\n";
$array['email_templates'][$x]['template_body'] .= "<strong>Event:</strong> \${event}<br />\n";
$array['email_templates'][$x]['template_body'] .= "</body>\n";
$array['email_templates'][$x]['template_body'] .= "</html>\n";
$array['email_templates'][$x]['template_type'] = 'html';