Add new macros %response.author.company%
This commit is contained in:
parent
8c4f6a1440
commit
89c52e3a12
@ -180,6 +180,7 @@ class HelpdeskMailSupport < MailHandler
|
||||
text = text.gsub(/\{%ticket.start_date%\}/, issue.start_date ? ApplicationHelper.format_date(issue.start_date) : '')
|
||||
text = text.gsub(/\{%ticket.public_url%\}/, full_url(URL_HELPER.public_ticket_path(issue.helpdesk_ticket.id, issue.helpdesk_ticket.token))) if text.match(/\{%ticket.public_url%\}/) && issue.helpdesk_ticket
|
||||
text = text.gsub(/%%NOTE_AUTHOR.JOB_TITLE%%|\{%response.author.job_title%\}/, Contact.where(email: journal_user.mail).pluck(:job_title).join('')) if journal_user
|
||||
text = text.gsub(/%%NOTE_AUTHOR.COMPANY%%|\{%response.author.company%\}/, Contact.where(email: journal_user.mail).pluck(:company).join('')) if journal_user
|
||||
if RedmineHelpdesk.vote_allow?
|
||||
text = text.gsub(/\{%ticket.voting%\}/, full_url(URL_HELPER.helpdesk_votes_show_path(issue.helpdesk_ticket.id, issue.helpdesk_ticket.token))) if text.match(/\{%ticket.voting%\}/)
|
||||
text = text.gsub(/\{%ticket.voting.good%\}/, full_url(URL_HELPER.helpdesk_votes_fast_vote_path(issue.helpdesk_ticket.id, 2, issue.helpdesk_ticket.token))) if text.match(/\{%ticket.voting.good%\}/)
|
||||
|
@ -32,7 +32,7 @@ class HelpdeskSettings
|
||||
{%ticket.project%} {%ticket.subject%} {%ticket.quoted_description%} {%ticket.history%} {%ticket.status%}
|
||||
{%ticket.priority%} {%ticket.estimated_hours%} {%ticket.done_ratio%} {%ticket.public_url%} {%ticket.closed_on%} {%ticket.due_date%}
|
||||
{%ticket.start_date%} {%ticket.voting%} {%ticket.voting.good%} {%ticket.voting.okay%} {%ticket.voting.bad%}
|
||||
{%response.author%} {%response.author.first_name%} {%response.author.last_name%} {%response.author.job_title%})
|
||||
{%response.author%} {%response.author.first_name%} {%response.author.last_name%} {%response.author.job_title%} {%response.author.company%})
|
||||
|
||||
FROM_MACRO_LIST = %w({%response.author%} {%response.author.first_name%})
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user