2
0
forked from Wavyzz/dolibarr

New Ref more visible when create a ticket

When customers call support to trace a ticket, they don't have easily ref of the ticket. Add Ref to the subject of mail for customers and for TICKET_NOTIFICATION_EMAIL_TO. Add ref also to the notification message when customers create a new ticket.
This commit is contained in:
Manu Bryk
2019-12-27 00:11:49 +01:00
committed by Laurent Destailleur
parent 3b6936176a
commit 14d69c5a2c
2 changed files with 6 additions and 6 deletions

View File

@@ -251,9 +251,9 @@ ShowListTicketWithTrackId=Display ticket list from track ID
ShowTicketWithTrackId=Display ticket from track ID ShowTicketWithTrackId=Display ticket from track ID
TicketPublicDesc=You can create a support ticket or check from an existing ID. TicketPublicDesc=You can create a support ticket or check from an existing ID.
YourTicketSuccessfullySaved=Ticket has been successfully saved! YourTicketSuccessfullySaved=Ticket has been successfully saved!
MesgInfosPublicTicketCreatedWithTrackId=A new ticket has been created with ID %s. MesgInfosPublicTicketCreatedWithTrackId=A new ticket has been created with ID %s and Ref %s.
PleaseRememberThisId=Please keep the tracking number that we might ask you later. PleaseRememberThisId=Please keep the tracking number that we might ask you later.
TicketNewEmailSubject=Ticket creation confirmation TicketNewEmailSubject=Ticket creation confirmation - Ref %s
TicketNewEmailSubjectCustomer=New support ticket TicketNewEmailSubjectCustomer=New support ticket
TicketNewEmailBody=This is an automatic email to confirm you have registered a new ticket. TicketNewEmailBody=This is an automatic email to confirm you have registered a new ticket.
TicketNewEmailBodyCustomer=This is an automatic email to confirm a new ticket has just been created into your account. TicketNewEmailBodyCustomer=This is an automatic email to confirm a new ticket has just been created into your account.
@@ -272,7 +272,7 @@ Subject=Subject
ViewTicket=View ticket ViewTicket=View ticket
ViewMyTicketList=View my ticket list ViewMyTicketList=View my ticket list
ErrorEmailMustExistToCreateTicket=Error: email address not found in our database ErrorEmailMustExistToCreateTicket=Error: email address not found in our database
TicketNewEmailSubjectAdmin=New ticket created TicketNewEmailSubjectAdmin=New ticket created - Ref %s
TicketNewEmailBodyAdmin=<p>Ticket has just been created with ID #%s, see information:</p> TicketNewEmailBodyAdmin=<p>Ticket has just been created with ID #%s, see information:</p>
SeeThisTicketIntomanagementInterface=See ticket in management interface SeeThisTicketIntomanagementInterface=See ticket in management interface
TicketPublicInterfaceForbidden=The public interface for the tickets was not enabled TicketPublicInterfaceForbidden=The public interface for the tickets was not enabled

View File

@@ -203,7 +203,7 @@ if ($action == 'create_ticket' && GETPOST('add', 'alpha')) {
// Send email to customer // Send email to customer
$subject = '['.$conf->global->MAIN_INFO_SOCIETE_NOM.'] '.$langs->transnoentities('TicketNewEmailSubject'); $subject = '['.$conf->global->MAIN_INFO_SOCIETE_NOM.'] '.$langs->transnoentities('TicketNewEmailSubject', $object->ref);
$message .= ($conf->global->TICKET_MESSAGE_MAIL_NEW ? $conf->global->TICKET_MESSAGE_MAIL_NEW : $langs->transnoentities('TicketNewEmailBody'))."\n\n"; $message .= ($conf->global->TICKET_MESSAGE_MAIL_NEW ? $conf->global->TICKET_MESSAGE_MAIL_NEW : $langs->transnoentities('TicketNewEmailBody'))."\n\n";
$message .= $langs->transnoentities('TicketNewEmailBodyInfosTicket')."\n"; $message .= $langs->transnoentities('TicketNewEmailBodyInfosTicket')."\n";
@@ -245,7 +245,7 @@ if ($action == 'create_ticket' && GETPOST('add', 'alpha')) {
if ($sendto) if ($sendto)
{ {
$subject = '['.$conf->global->MAIN_INFO_SOCIETE_NOM.'] '.$langs->transnoentities('TicketNewEmailSubjectAdmin'); $subject = '['.$conf->global->MAIN_INFO_SOCIETE_NOM.'] '.$langs->transnoentities('TicketNewEmailSubjectAdmin', $object->ref);
$message_admin = $langs->transnoentities('TicketNewEmailBodyAdmin', $object->track_id)."\n\n"; $message_admin = $langs->transnoentities('TicketNewEmailBodyAdmin', $object->track_id)."\n\n";
$message_admin .= '<ul><li>'.$langs->trans('Title').' : '.$object->subject.'</li>'; $message_admin .= '<ul><li>'.$langs->trans('Title').' : '.$object->subject.'</li>';
$message_admin .= '<li>'.$langs->trans('Type').' : '.$object->type_label.'</li>'; $message_admin .= '<li>'.$langs->trans('Type').' : '.$object->type_label.'</li>';
@@ -314,7 +314,7 @@ if ($action == 'create_ticket' && GETPOST('add', 'alpha')) {
//setEventMessages($langs->trans('YourTicketSuccessfullySaved'), null, 'mesgs'); //setEventMessages($langs->trans('YourTicketSuccessfullySaved'), null, 'mesgs');
// Make a redirect to avoid to have ticket submitted twice if we make back // Make a redirect to avoid to have ticket submitted twice if we make back
setEventMessages($langs->trans('MesgInfosPublicTicketCreatedWithTrackId', '<strong>'.$object->track_id.'</strong>'), null, 'warnings'); setEventMessages($langs->trans('MesgInfosPublicTicketCreatedWithTrackId', '<strong>'.$object->track_id.'</strong>', '<strong>' . $object->ref . '</strong>'), null, 'warnings');
setEventMessages($langs->trans('PleaseRememberThisId'), null, 'warnings'); setEventMessages($langs->trans('PleaseRememberThisId'), null, 'warnings');
header("Location: index.php"); header("Location: index.php");
exit; exit;