#330 Add MESSAGE_NO_ATTACHMENTS tag
This commit is contained in:
parent
f38bff6e0c
commit
77489d8eef
@ -289,6 +289,7 @@ function getSpecialTagMap() {
|
||||
$map['%%EMAIL%%'] = $hesklang['customer_email'];
|
||||
$map['%%SUBJECT%%'] = $hesklang['ticket_subject'];
|
||||
$map['%%MESSAGE%%'] = $hesklang['ticket_message'];
|
||||
$map['%%MESSAGE_NO_ATTACHMENTS%%'] = $hesklang['ticket_message_no_attachments'];
|
||||
$map['%%CREATED%%'] = $hesklang['ticket_created'];
|
||||
$map['%%UPDATED%%'] = $hesklang['ticket_updated'];
|
||||
$map['%%TRACK_ID%%'] = $hesklang['ticket_trackID'];
|
||||
|
@ -738,8 +738,10 @@ function hesk_processMessage($msg, $ticket, $is_admin, $is_ticket, $just_message
|
||||
if ($isForHtml)
|
||||
{
|
||||
$htmlMessage = nl2br($ticket['message']);
|
||||
$msg = str_replace('%%MESSAGE_NO_ATTACHMENTS%%', $htmlMessage, $msg);
|
||||
return str_replace('%%MESSAGE%%', $htmlMessage, $msg);
|
||||
}
|
||||
$msg = str_replace('%%MESSAGE_NO_ATTACHMENTS%%', $ticket['message'], $msg);
|
||||
return str_replace('%%MESSAGE%%', $ticket['message'], $msg);
|
||||
}
|
||||
else
|
||||
@ -863,6 +865,15 @@ function hesk_processMessage($msg, $ticket, $is_admin, $is_ticket, $just_message
|
||||
{
|
||||
$msg = $hesklang['EMAIL_HR'] . "\n\n" . $msg;
|
||||
}
|
||||
} elseif (strpos($msg, '%%MESSAGE_NO_ATTACHMENTS%%') !== false) {
|
||||
if ($isForHtml)
|
||||
{
|
||||
$htmlMessage = nl2br($ticket['message']);
|
||||
$msg = str_replace('%%MESSAGE_NO_ATTACHMENTS%%', $htmlMessage, $msg);
|
||||
} else
|
||||
{
|
||||
$msg = str_replace('%%MESSAGE_NO_ATTACHMENTS%%',$ticket['message'],$msg);
|
||||
}
|
||||
}
|
||||
|
||||
return $msg;
|
||||
|
@ -21,6 +21,9 @@ $hesklang['_COLLATE']='utf8_unicode_ci';
|
||||
// This is the email break line that will be used in email piping
|
||||
$hesklang['EMAIL_HR']='------ Reply above this line ------';
|
||||
|
||||
// ADDED OR MODIFIED IN Mods for HESK 2.5.0
|
||||
$hesklang['ticket_message_no_attachments'] = 'Ticket/Reply message, however attachments will not be included in the email';
|
||||
|
||||
// ADDED OR MODIFIED IN Mods for HESK 2.4.0
|
||||
$hesklang['sort_by_user_defined_order'] = 'Sort by user-defined order';
|
||||
$hesklang['sort_alphabetically'] = 'Sort alphabetically';
|
||||
|
Loading…
x
Reference in New Issue
Block a user