/build/static/layout/Breadcrumb_cap_w.png

Sending emails to the owners of tickets

Since I upgraded to 6.2 the owners of each ticket are getting overwhelmed with email updates from tickets.  The only events I have turned on are comments for the submitter and cc list.

I am sending an email to the owners that has the admin url in it and this works but every change that is made to the ticket the owners are now getting an email including if the owner comments on their own ticket.  Nothing was changed and this just started happening.  Below is the email that gets sent to the owners:

Query
select HD_TICKET.ID, 
HD_TICKET.ID as TICKNUM, 
HD_TICKET.TITLE, 
U1.USER_NAME as OWNER_NAME, 
U3.USER_NAME as LASTINPUTNAME,  
DATE_FORMAT(HD_TICKET.CREATED,'%b %d %Y %I:%i:%s %p') as CREATED, 
DATE_FORMAT(HD_TICKET.MODIFIED,'%b %d %Y %I:%i:%s %p') as MODIFIED, 
HD_STATUS.NAME AS STATUS_NAME, 
HD_STATUS.ORDINAL as STATUS_ORDINAL, 
STATE, 
U1.FULL_NAME as OWNER_FULLNAME, 
U1.EMAIL as OWNER_EMAIL, 
U2.USER_NAME as SUBMITTER_NAME, 
U2.FULL_NAME as SUBMITTER_FULLNAME, 
U2.EMAIL as SUBMITTER_EMAIL, 
U3.EMAIL as UPDATEREMAIL, 
U3.FULL_NAME as UPDATERNAME,
U4.FULL_NAME as INITIALNAME,
UNIX_TIMESTAMP(HD_TICKET_CHANGE.TIMESTAMP),
HD_TICKET_CHANGE.COMMENT,
HD_TICKET_CHANGE.DESCRIPTION as CHANGE_DESCRIPTION,
INITIAL_CHANGE.COMMENT as INITIAL_COMMENT,
HD_CATEGORY.CC_LIST AS NEWTICKETEMAIL,
HD_CATEGORY.NAME AS CATEGORY_NAME,
U2.LOCATION AS SUBMITTER_LOCATION,
U2.WORK_PHONE AS SUBMITTER_WORK_PHONE,
HD_PRIORITY.NAME AS TICKET_PRIORITY,
HD_FIELD.NAME AS QUEUE_NAME
from ( HD_TICKET, 
HD_PRIORITY, 
HD_STATUS, 
HD_IMPACT, 
HD_CATEGORY)
JOIN HD_TICKET_CHANGE ON HD_TICKET_CHANGE.HD_TICKET_ID = HD_TICKET.ID 
 JOIN HD_TICKET_CHANGE INITIAL_CHANGE ON INITIAL_CHANGE.HD_TICKET_ID = HD_TICKET.ID
 and INITIAL_CHANGE.ID=(select MIN(ID) from HD_TICKET_CHANGE where HD_TICKET_CHANGE.HD_TICKET_ID = HD_TICKET.ID)
left join USER U1 on U1.ID = HD_TICKET.OWNER_ID
left join USER U2 on U2.ID = HD_TICKET.SUBMITTER_ID 
left join USER U3 on U3.ID = HD_TICKET_CHANGE.USER_ID 
left join USER U4 on U4.ID = INITIAL_CHANGE.USER_ID
left join HD_FIELD on HD_FIELD.ID = HD_TICKET.HD_QUEUE_ID
where HD_PRIORITY.ID = HD_PRIORITY_ID  and 
HD_STATUS.ID = HD_STATUS_ID  and 
HD_IMPACT.ID = HD_IMPACT_ID  and 
HD_CATEGORY.ID = HD_CATEGORY_ID  and
HD_TICKET.OWNER_ID != HD_TICKET_CHANGE.USER_ID and
HD_TICKET_CHANGE.DESCRIPTION not like "%Ticket Created%" and
U1.EMAIL != 'tsc@ashland.edu' and 
HD_TICKET.HD_QUEUE_ID = 1 and
HD_STATUS.NAME != 'Closed'

Subject:[TICK:$id], has been updated 
Column containing email addresses: OWNER_EMAIL

Message:
You are receiving this email because you are the owner of this ticket.

Title: $title
Submitter: $submitter_fullname
Category: $category_name
Priority: $ticket_priority

Changes:
$change_description

Comment ($updatername): 
$comment

Initial Comment ($initialname):
$initial_comment

View the ticket here:
https://kbox.it.ashland.edu/adminui/ticket?ID=$ticknum


1 Comment   [ + ] Show comment
  • I am not sure why it wasn't working like this in the past either. How would I change this so the only time the owner would get emailed is if a comment was changed and by someone other than the owner. - scarpent 8 years ago

Answers (1)

Posted by: chucksteel 8 years ago
Red Belt
2
This rule should have been working similarly in earlier versions, meaning I don't know why emails were not being sent on every change previously. This rule should not email the technician if they make a change on a ticket where they are the owner, so I'm not sure why that is happening. You can try checking the box for "Email results" and having that sent to your inbox. This will send you the results of the query and helps debug what the rule is selecting.

Don't be a Stranger!

Sign up today to participate, stay informed, earn points and establish a reputation for yourself!

Sign up! or login

Share

 
This website uses cookies. By continuing to use this site and/or clicking the "Accept" button you are providing consent Quest Software and its affiliates do NOT sell the Personal Data you provide to us either when you register on our websites or when you do business with us. For more information about our Privacy Policy and our data protection efforts, please visit GDPR-HQ