Closed (fixed)
Project:
Support Ticketing System
Version:
6.x-1.0-rc2
Component:
Code
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Reporter:
Created:
19 Jun 2009 at 18:54 UTC
Updated:
31 Jul 2009 at 22:00 UTC
For my application, I needed to add the Client Name to the outbound email to go along with the State and Priority.
This is what I was able to get to work.
function support_mail_tokens(
- added this line
$client_client = db_result(db_query('SELECT name FROM {support_client} WHERE clid = %d', $node->client));
$tokens = array(
- added this token
'!client' => $client_client,
Since I am a NOOB to PHP, I am sure that there is probably a cleaner/easier way to declare $client_client, but this worked.
Comments
Comment #1
jeremy commentedI have exported both '!client_name' and '!client_path'. Be sure to rename 'client' to 'client_name' in your email text when you upgrade. Feature implemented.
Comment #2
roball commentedWhere can I configure to add the client name to the notifying e-mails, just like
Client: XY
State: new
Priority: critical
? Thanks.
Comment #3
jeremy commentedThis is documented in MAIL.txt. You do so in settings.php.
Comment #4
roball commentedThank you, just read MAIL.txt. The new !client_name and !client_path tokens are missing in the documented supported tokens.
BTW, what does the last line in notification mails (like [54:a684eceee76fc522773286a895bc8436]) mean? I can't find any documentation about that.
Thanks.
Comment #5
jeremy commentedI've updated MAIL.txt, thanks.
The [##:HEXCODE] tag found at the end of emails is used to try and filter out tickets when they are quoted in entirety when replying to tickets by email. It doesn't work all that well, sadly. If you want to discuss it further, please do so in another ticket as this ticket is about adding the client* tokens.