Fixes #2661 - Inconsistency in "follow up" strings

This commit is contained in:
Denny Bresch 2019-08-16 17:39:31 +02:00 committed by Thorsten Eckel
parent 6a5c5a3e2a
commit 832b2ec28a
27 changed files with 70 additions and 70 deletions

View file

@ -645,7 +645,7 @@ class App.TicketZoom extends App.Controller
state = App.TicketState.findByAttribute('id', @ticket.state_id)
return if state && state.default_create is true
# prevent multiple changes for the default follow up state
# prevent multiple changes for the default follow-up state
@isDefaultFollowUpStateSet = true
# get state
@ -952,7 +952,7 @@ class App.TicketZoom extends App.Controller
# reset task
@taskReset()
# reset default follow up state
# reset default follow-up state
@resetDefaultFollowUpState()
# reset/delete uploaded attachments

View file

@ -6,8 +6,8 @@ class App.Group extends App.Model
@configure_attributes = [
{ name: 'name', display: 'Name', tag: 'input', type: 'text', limit: 100, null: false },
{ name: 'assignment_timeout', display: 'Assignment Timeout', tag: 'input', note: 'Assignment timeout in minutes if assigned agent is not working on it. Ticket will be shown as unassigend.', type: 'text', limit: 100, null: true },
{ name: 'follow_up_possible', display: 'Follow up possible',tag: 'select', default: 'yes', options: { yes: 'yes', 'new_ticket': 'do not reopen Ticket but create new Ticket' }, null: false, note: 'Follow up for closed ticket possible or not.', translate: true },
{ name: 'follow_up_assignment', display: 'Assign Follow Ups', tag: 'select', default: 'yes', options: { true: 'yes', false: 'no' }, null: false, note: 'Assign follow up to latest agent again.', translate: true },
{ name: 'follow_up_possible', display: 'Follow-up possible',tag: 'select', default: 'yes', options: { yes: 'yes', 'new_ticket': 'do not reopen Ticket but create new Ticket' }, null: false, note: 'Follow-up for closed ticket possible or not.', translate: true },
{ name: 'follow_up_assignment', display: 'Assign Follow-Ups', tag: 'select', default: 'yes', options: { true: 'yes', false: 'no' }, null: false, note: 'Assign follow-up to latest agent again.', translate: true },
{ name: 'email_address_id', display: 'Email', tag: 'select', multiple: false, null: true, relation: 'EmailAddress', nulloption: true, do_not_log: true },
{ name: 'signature_id', display: 'Signature', tag: 'select', multiple: false, null: true, relation: 'Signature', nulloption: true, do_not_log: true },
{ name: 'note', display: 'Note', tag: 'textarea', note: 'Notes are visible to agents only, never to customers.', limit: 250, null: true },

View file

@ -20,7 +20,7 @@ class Integration::CheckMkController < ApplicationController
# check if ticket with host is open
customer = User.lookup(id: 1)
# follow up detection by meta data
# follow-up detection by meta data
integration = 'check_mk'
open_states = Ticket::State.by_category(:open)
ticket_ids = Ticket.where(state: open_states).order(created_at: :desc).limit(5000).pluck(:id)

View file

@ -675,7 +675,7 @@ class TicketsController < ApplicationController
return true if ticket.group.follow_up_possible != 'new_ticket' # check if the setting for follow_up_possible is disabled
return true if ticket.state.name != 'closed' # check if the ticket state is already closed
raise Exceptions::UnprocessableEntity, 'Cannot follow up on a closed ticket. Please create a new ticket.'
raise Exceptions::UnprocessableEntity, 'Cannot follow-up on a closed ticket. Please create a new ticket.'
end
def ticket_all(ticket)

View file

@ -21,7 +21,7 @@ module Channel::Filter::BounceFollowUpCheck
article = Ticket::Article.where(message_id_md5: message_id_md5).order('created_at DESC, id DESC').limit(1).first
next if !article
Rails.logger.debug { "Follow up for '##{article.ticket.number}' in bounce email." }
Rails.logger.debug { "Follow-up for '##{article.ticket.number}' in bounce email." }
mail[ 'x-zammad-ticket-id'.to_sym ] = article.ticket_id
mail[ 'x-zammad-is-auto-response'.to_sym ] = true

View file

@ -9,7 +9,7 @@ module Channel::Filter::FollowUpCheck
# get ticket# from subject
ticket = Ticket::Number.check(mail[:subject])
if ticket
Rails.logger.debug { "Follow up for '##{ticket.number}' in subject." }
Rails.logger.debug { "Follow-up for '##{ticket.number}' in subject." }
mail['x-zammad-ticket-id'.to_sym] = ticket.id
return true
end
@ -20,7 +20,7 @@ module Channel::Filter::FollowUpCheck
if setting.include?('body')
ticket = Ticket::Number.check(mail[:body].html2text)
if ticket
Rails.logger.debug { "Follow up for '##{ticket.number}' in body." }
Rails.logger.debug { "Follow-up for '##{ticket.number}' in body." }
mail['x-zammad-ticket-id'.to_sym] = ticket.id
return true
end
@ -34,7 +34,7 @@ module Channel::Filter::FollowUpCheck
ticket = Ticket::Number.check(attachment[:data].html2text)
next if !ticket
Rails.logger.debug { "Follow up for '##{ticket.number}' in attachment." }
Rails.logger.debug { "Follow-up for '##{ticket.number}' in attachment." }
mail['x-zammad-ticket-id'.to_sym] = ticket.id
return true
end
@ -61,7 +61,7 @@ module Channel::Filter::FollowUpCheck
article = Ticket::Article.where(message_id_md5: message_id_md5).order('created_at DESC, id DESC').limit(1).first
next if !article
Rails.logger.debug { "Follow up for '##{article.ticket.number}' in references." }
Rails.logger.debug { "Follow-up for '##{article.ticket.number}' in references." }
mail['x-zammad-ticket-id'.to_sym] = article.ticket_id
return true
end
@ -102,7 +102,7 @@ module Channel::Filter::FollowUpCheck
# if subject is different, it's no followup
next if subject_to_check != article_first.subject
Rails.logger.debug { "Follow up for '##{article.ticket.number}' in references with same subject as inital article." }
Rails.logger.debug { "Follow-up for '##{article.ticket.number}' in references with same subject as inital article." }
mail['x-zammad-ticket-id'.to_sym] = article_first.ticket_id
return true
end

View file

@ -10,7 +10,7 @@ module Channel::Filter::FollowUpPossibleCheck
return true if !ticket
return true if ticket.state.state_type.name !~ /^(closed|merged|removed)/i
# in case of closed tickets, remove follow up information
# in case of closed tickets, remove follow-up information
case ticket.group.follow_up_possible
when 'new_ticket'
mail[:subject] = ticket.subject_clean(mail[:subject])

View file

@ -80,7 +80,7 @@ class Channel::Filter::MonitoringBase
end
end
# follow up detection by meta data
# follow-up detection by meta data
open_states = Ticket::State.by_category(:open)
ticket_ids = Ticket.where(state: open_states).order(created_at: :desc).limit(5000).pluck(:id)
ticket_ids.each do |ticket_id|

View file

@ -111,7 +111,7 @@ class Observer::Ticket::ArticleChanges < ActiveRecord::Observer
ticket = record.ticket
if sender.name == 'Customer'
# in case, update last_contact_customer_at on any customer follow up
# in case, update last_contact_customer_at on any customer follow-up
if Setting.get('ticket_last_contact_behaviour') == 'based_on_customer_reaction'
# set last_contact_at customer

View file

@ -16,7 +16,7 @@ class FixedTypos622 < ActiveRecord::Migration[4.2]
'password_min_2_lower_2_upper_characters' => 'Password needs to contain 2 lower and 2 upper characters.',
'password_need_digit' => 'Password needs to have at least one digit.',
'ticket_subject_size' => 'Max size of the subject in an email reply.',
'postmaster_follow_up_search_in' => 'In default the follow up check is done via the subject of an email. With this setting you can add more fields where the follow up check is executed.',
'postmaster_follow_up_search_in' => 'In default the follow-up check is done via the subject of an email. With this setting you can add more fields where the follow-up check is executed.',
}
setting_map.each do |key, description|

View file

@ -8,7 +8,7 @@ class FollowUpPossibleCheck643 < ActiveRecord::Migration[4.2]
title: 'Define postmaster filter.',
name: '0200_postmaster_filter_follow_up_possible_check',
area: 'Postmaster::PreFilter',
description: 'Define postmaster filter to check if follow ups get created (based on admin settings).',
description: 'Define postmaster filter to check if follow-ups get created (based on admin settings).',
options: {},
state: 'Channel::Filter::FollowUpPossibleCheck',
frontend: false
@ -18,7 +18,7 @@ class FollowUpPossibleCheck643 < ActiveRecord::Migration[4.2]
force: true,
object: 'Group',
name: 'follow_up_possible',
display: 'Follow up possible',
display: 'Follow-up possible',
data_type: 'select',
data_option: {
default: 'yes',
@ -27,7 +27,7 @@ class FollowUpPossibleCheck643 < ActiveRecord::Migration[4.2]
new_ticket: 'do not reopen Ticket but create new Ticket'
},
null: false,
note: 'Follow up for closed ticket possible or not.',
note: 'Follow-up for closed ticket possible or not.',
translate: true
},
editable: false,

View file

@ -4,7 +4,7 @@ class TriggerRecipientUpdate < ActiveRecord::Migration[4.2]
# return if it's a new setup
return if !Setting.find_by(name: 'system_init_done')
['auto reply (on new tickets)', 'auto reply (on follow up of tickets)'].each do |name|
['auto reply (on new tickets)', 'auto reply (on follow-up of tickets)'].each do |name|
trigger = Trigger.find_by(name: name)
next if trigger.blank?

View file

@ -1495,7 +1495,7 @@ ObjectManager::Attribute.add(
force: true,
object: 'Group',
name: 'follow_up_possible',
display: 'Follow up possible',
display: 'Follow-up possible',
data_type: 'select',
data_option: {
default: 'yes',
@ -1504,7 +1504,7 @@ ObjectManager::Attribute.add(
new_ticket: 'do not reopen Ticket but create new Ticket'
},
null: false,
note: 'Follow up for closed ticket possible or not.',
note: 'Follow-up for closed ticket possible or not.',
translate: true
},
editable: false,
@ -1531,7 +1531,7 @@ ObjectManager::Attribute.add(
force: true,
object: 'Group',
name: 'follow_up_assignment',
display: 'Assign Follow Ups',
display: 'Assign Follow-Ups',
data_type: 'select',
data_option: {
default: 'yes',
@ -1540,7 +1540,7 @@ ObjectManager::Attribute.add(
false: 'no',
},
null: false,
note: 'Assign follow up to latest agent again.',
note: 'Assign follow-up to latest agent again.',
translate: true
},
editable: false,

View file

@ -2515,9 +2515,9 @@ Setting.create_if_not_exists(
name: 'postmaster_follow_up_search_in',
tag: 'checkbox',
options: {
'references' => 'References - Search for follow up also in In-Reply-To or References headers.',
'body' => 'Body - Search for follow up also in mail body.',
'attachment' => 'Attachment - Search for follow up also in attachments.',
'references' => 'References - Search for follow-up also in In-Reply-To or References headers.',
'body' => 'Body - Search for follow-up also in mail body.',
'attachment' => 'Attachment - Search for follow-up also in attachments.',
},
},
],
@ -3309,7 +3309,7 @@ Setting.create_if_not_exists(
title: 'Defines postmaster filter.',
name: '0200_postmaster_filter_follow_up_possible_check',
area: 'Postmaster::PreFilter',
description: 'Define postmaster filter to check if follow ups get created (based on admin settings).',
description: 'Define postmaster filter to check if follow-ups get created (based on admin settings).',
options: {},
state: 'Channel::Filter::FollowUpPossibleCheck',
frontend: false

View file

@ -42,7 +42,7 @@ Trigger.create_or_update(
updated_by_id: 1,
)
Trigger.create_or_update(
name: 'auto reply (on follow up of tickets)',
name: 'auto reply (on follow-up of tickets)',
condition: {
'ticket.action' => {
'operator' => 'is',
@ -63,7 +63,7 @@ Trigger.create_or_update(
},
perform: {
'notification.email' => {
'body' => '<div>Your follow up for <b>(#{config.ticket_hook}#{ticket.number})</b> has been received and will be reviewed by our support staff.</div>
'body' => '<div>Your follow-up for <b>(#{config.ticket_hook}#{ticket.number})</b> has been received and will be reviewed by our support staff.</div>
<br/>
<div>To provide additional information, please reply to this email or click on the following link:
<a href="#{config.http_type}://#{config.fqdn}/#ticket/zoom/#{ticket.id}">#{config.http_type}://#{config.fqdn}/#ticket/zoom/#{ticket.id}</a>
@ -73,7 +73,7 @@ Trigger.create_or_update(
<br/>
<div><i><a href="https://zammad.com">Zammad</a>, your customer support system</i></div>',
'recipient' => 'article_last_sender',
'subject' => 'Thanks for your follow up (#{ticket.title})', # rubocop:disable Lint/InterpolationCheck
'subject' => 'Thanks for your follow-up (#{ticket.title})', # rubocop:disable Lint/InterpolationCheck
},
},
active: false,

View file

@ -78,7 +78,7 @@ RSpec.describe 'Twilio SMS', type: :request do
expect(article.to).to eq('+4915700000000')
expect(article.cc).to be_nil
expect(article.subject).to be_nil
expect(article.body).to eq('Follow up')
expect(article.body).to eq('Follow-up')
expect(article.sender.name).to eq('Customer')
expect(article.type.name).to eq('sms')
expect(article.created_by_id).to eq(customer.id)

View file

@ -2104,7 +2104,7 @@ RSpec.describe 'Ticket', type: :request do
as: :json
expect(response).to have_http_status(:unprocessable_entity)
expect(json_response).to include('error' => 'Cannot follow up on a closed ticket. Please create a new ticket.')
expect(json_response).to include('error' => 'Cannot follow-up on a closed ticket. Please create a new ticket.')
end
end

View file

@ -105,7 +105,7 @@ class CustomerTicketCreateTest < TestCase
value: 'closed',
)
# type in new content into rte to trigger the default follow up state
# type in new content into rte to trigger the default follow-up state
set(
css: '.content.active [data-name="body"]',
value: 'some body blublub default followup for reopen check',
@ -120,7 +120,7 @@ class CustomerTicketCreateTest < TestCase
# no we verify the reverse way:
# if the body get changed to empty again then
# the default follow up state should get unset and
# the default follow-up state should get unset and
# will change to the the default ticket state.
# remove content from rte
@ -136,7 +136,7 @@ class CustomerTicketCreateTest < TestCase
value: 'closed',
)
# type in new content into rte to trigger the default follow up state
# type in new content into rte to trigger the default follow-up state
set(
css: '.content.active [data-name="body"]',
value: 'some body blublub default followup for reopen check',

View file

@ -70,7 +70,7 @@ Date: Fri, 26 May 2017 17:01:45 +0200
From: Twelve SaaS GmbH Helpdesk <example@zammad.com>
To: ticket-bounce-trigger2@example.com
Message-ID: <20170526150141.232.13312@example.zammad.loc>
In-Reply-To:
In-Reply-To:
References: <20170526150142.232.819805@example.zammad.loc>
<20170526150119.6C5E520A13B2@mx1.zammad.loc>
<20170526150141.232.799457@example.zammad.loc>
@ -115,7 +115,7 @@ Content-Type: text/plain;
charset=UTF-8
Content-Transfer-Encoding: 7bit
Your follow up for (Ticket#1705265400361) has been received and will be reviewed by our support staff.
Your follow-up for (Ticket#1705265400361) has been received and will be reviewed by our support staff.
To provide additional information, please reply to this email or click on the following link:[1] https://example.zammad.loc/#ticket/zoom/232
@ -210,7 +210,7 @@ Content-Type: text/html;
}
</style>
</head>
<body style="font-family:'Helvetica Neue', Helvetica, Arial, Geneva, sans-serif; font-size: 12px;"><div>Your follow up for <b>(Ticket#1705265400361)</b> has been received and will be reviewed by our support staff.</div>
<body style="font-family:'Helvetica Neue', Helvetica, Arial, Geneva, sans-serif; font-size: 12px;"><div>Your follow-up for <b>(Ticket#1705265400361)</b> has been received and will be reviewed by our support staff.</div>
<br>
<div>To provide additional information, please reply to this email or click on the following link:
<a href="https://example.zammad.loc/#ticket/zoom/232" rel="nofollow noreferrer noopener" target="_blank">https://example.zammad.loc/#ticket/zoom/232</a>

View file

@ -9,7 +9,7 @@
"FromState": "",
"SmsStatus": "received",
"FromCity": "",
"Body": "Follow up",
"Body": "Follow-up",
"FromCountry": "DE",
"To": "+4915700000000",
"ToZip": "",

View file

@ -569,7 +569,7 @@ Some Text'
PostmasterFilter.destroy_all
# follow up with create post master filter test
# follow-up with create post master filter test
PostmasterFilter.create!(
name: 'used - empty selector',
match: {
@ -592,7 +592,7 @@ Some Text'
data = 'From: Some Body <somebody@example.com>
To: Bob <bod@example.com>
Cc: any@example.com
Subject: follow up with create post master filter test
Subject: follow-up with create post master filter test
Some Text'
@ -601,7 +601,7 @@ Some Text'
assert_equal(group2.name, ticket.group.name)
assert_equal('2 normal', ticket.priority.name)
assert_equal('follow up with create post master filter test', ticket.title)
assert_equal('follow-up with create post master filter test', ticket.title)
assert_equal('Customer', article.sender.name)
assert_equal('email', article.type.name)
@ -628,7 +628,7 @@ Some Text"
assert_equal(group1.name, ticket_followup.group.name)
assert_equal(group1.name, ticket_followup.group.name)
assert_equal('2 normal', ticket_followup.priority.name)
assert_equal('follow up with create post master filter test', ticket_followup.title)
assert_equal('follow-up with create post master filter test', ticket_followup.title)
assert_equal('Customer', article.sender.name)
assert_equal('email', article.type.name)

View file

@ -50,11 +50,11 @@ Some Text"
assert_equal('Agent', article.sender.name)
assert_equal('me+is+customer@example.com', ticket.customer.email)
# check if follow up based on inital system sender address
# check if follow-up based on inital system sender address
setting_orig = Setting.get('postmaster_follow_up_search_in')
Setting.set('postmaster_follow_up_search_in', [])
# follow up possible because same subject
# follow-up possible because same subject
email_raw_string = "From: me+is+customer@example.com
To: myzammad@system.test
Subject: #{subject}
@ -68,7 +68,7 @@ Some Text"
assert_equal(subject, ticket2.title)
assert_equal(ticket.id, ticket2.id)
# follow up not possible because subject has changed
# follow-up not possible because subject has changed
subject = "new subject without ticket ref #{rand(9_999_999)}"
email_raw_string = "From: me+is+customer@example.com
To: myzammad@system.test

View file

@ -177,7 +177,7 @@ Comment: [] =
assert_equal('WARNING', ticket_2.preferences['icinga']['state'])
assert_not_equal(ticket_2.id, ticket_1.id)
# matching sender - follow up - CPU Load/host.internal.loc
# matching sender - follow-up - CPU Load/host.internal.loc
email_raw_string = "To: support@example.com
Subject: PROBLEM - host.internal.loc - CPU Load is WARNING
User-Agent: Heirloom mailx 12.5 7/5/10
@ -212,7 +212,7 @@ Comment: [] =
assert_equal('WARNING', ticket_1_1.preferences['icinga']['state'])
assert_equal(ticket_1.id, ticket_1_1.id)
# matching sender - follow up - recovery - CPU Load/host.internal.loc
# matching sender - follow-up - recovery - CPU Load/host.internal.loc
email_raw_string = "To: support@example.com
Subject: PROBLEM - host.internal.loc - CPU Load is WARNING
User-Agent: Heirloom mailx 12.5 7/5/10
@ -522,7 +522,7 @@ Comment: [] =
test 'matching sender tests' do
# matching sender - follow up - CPU Load/host.internal.loc
# matching sender - follow-up - CPU Load/host.internal.loc
email_raw_string = "To: support@example.com
Subject: PROBLEM - host.internal.loc - CPU Load is WARNING
User-Agent: Heirloom mailx 12.5 7/5/10

View file

@ -77,7 +77,7 @@ WARNING - load average: 3.44, 0.99, 0.35
assert_equal('WARNING', ticket_2.preferences['nagios']['state'])
assert_not_equal(ticket_2.id, ticket_1.id)
# matching sender - follow up - CPU Load/host.internal.loc
# matching sender - follow-up - CPU Load/host.internal.loc
email_raw_string = "To: support@example.com
Subject: ** PROBLEM Service Alert: host.internal.loc/CPU Load is WARNING **
MIME-Version: 1.0
@ -110,7 +110,7 @@ WARNING - load average: 3.44, 0.99, 0.35
assert_equal('WARNING', ticket_1_1.preferences['nagios']['state'])
assert_equal(ticket_1.id, ticket_1_1.id)
# matching sender - follow up - recovery - CPU Load/host.internal.loc
# matching sender - follow-up - recovery - CPU Load/host.internal.loc
email_raw_string = "To: support@example.com
Subject: ** PROBLEM Service Alert: host.internal.loc/CPU Load is WARNING **
MIME-Version: 1.0
@ -305,7 +305,7 @@ WARNING - load average: 3.44, 0.99, 0.35
test 'matching sender tests' do
# matching sender - follow up - CPU Load/host.internal.loc
# matching sender - follow-up - CPU Load/host.internal.loc
email_raw_string = "To: support@example.com
Subject: ** PROBLEM Service Alert: host.internal.loc/CPU Load is WARNING **
MIME-Version: 1.0

View file

@ -272,7 +272,7 @@ class OnlineNotificationTest < ActiveSupport::TestCase
Observer::Transaction.commit
Scheduler.worker(true)
# because it's already closed but an follow up arrived later
# because it's already closed but an follow-up arrived later
assert_not(OnlineNotification.all_seen?('Ticket', ticket3.id))
assert(OnlineNotification.exists?(@agent_user1, 'Ticket', ticket3.id, 'update', @customer_user, false))
assert(OnlineNotification.exists?(@agent_user1, 'Ticket', ticket3.id, 'update', @customer_user, true))

View file

@ -644,7 +644,7 @@ class TicketTriggerRecursiveDisabledTest < ActiveSupport::TestCase
)
Trigger.create_or_update(
name: 'auto reply (on follow up of tickets)',
name: 'auto reply (on follow-up of tickets)',
condition: {
'ticket.action' => {
'operator' => 'is',
@ -665,7 +665,7 @@ class TicketTriggerRecursiveDisabledTest < ActiveSupport::TestCase
},
perform: {
'notification.email' => {
'body' => '<p>Your follow up for (#{config.ticket_hook}##{ticket.number}) has been received and will be reviewed by our support staff.<p>
'body' => '<p>Your follow-up for (#{config.ticket_hook}##{ticket.number}) has been received and will be reviewed by our support staff.<p>
<br/>
<p>To provide additional information, please reply to this email or click on the following link:
<a href="#{config.http_type}://#{config.fqdn}/#ticket/zoom/#{ticket.id}">#{config.http_type}://#{config.fqdn}/#ticket/zoom/#{ticket.id}</a>
@ -673,7 +673,7 @@ class TicketTriggerRecursiveDisabledTest < ActiveSupport::TestCase
<br/>
<p><i><a href="http://zammad.com">Zammad</a>, your customer support system</i></p>',
'recipient' => 'ticket_customer',
'subject' => 'Thanks for your follow up (#{ticket.title})',
'subject' => 'Thanks for your follow-up (#{ticket.title})',
},
},
active: true,
@ -793,7 +793,7 @@ class TicketTriggerRecursiveDisabledTest < ActiveSupport::TestCase
assert_equal(6, ticket_p.articles.count, 'ticket_p.articles verify')
article_p = ticket_p.articles.last
assert_match('Thanks for your follow up (aaäöüßad asd)', article_p.subject)
assert_match('Thanks for your follow-up (aaäöüßad asd)', article_p.subject)
assert_match('Zammad <zammad@localhost>', article_p.from)
assert_no_match('config\.', article_p.body)
assert_match('http://zammad.example.com', article_p.body)
@ -824,7 +824,7 @@ class TicketTriggerRecursiveDisabledTest < ActiveSupport::TestCase
assert_equal(8, ticket_p.articles.count, 'ticket_p.articles verify')
article_p = ticket_p.articles.last
assert_match('Thanks for your follow up (aaäöüßad asd)', article_p.subject)
assert_match('Thanks for your follow-up (aaäöüßad asd)', article_p.subject)
assert_match('Zammad <zammad@localhost>', article_p.from)
assert_no_match('config\.', article_p.body)
assert_match('http://zammad.example.com', article_p.body)
@ -2528,7 +2528,7 @@ class TicketTriggerRecursiveDisabledTest < ActiveSupport::TestCase
updated_by_id: 1,
)
Trigger.create_or_update(
name: 'auto reply (on follow up of tickets)',
name: 'auto reply (on follow-up of tickets)',
condition: {
'ticket.action' => {
'operator' => 'is',
@ -2549,7 +2549,7 @@ class TicketTriggerRecursiveDisabledTest < ActiveSupport::TestCase
},
perform: {
'notification.email' => {
'body' => '<div>Your follow up for <b>(#{config.ticket_hook}#{ticket.number})</b> has been received and will be reviewed by our support staff.</div>
'body' => '<div>Your follow-up for <b>(#{config.ticket_hook}#{ticket.number})</b> has been received and will be reviewed by our support staff.</div>
<br/>
<div>To provide additional information, please reply to this email or click on the following link:
<a href="#{config.http_type}://#{config.fqdn}/#ticket/zoom/#{ticket.id}">#{config.http_type}://#{config.fqdn}/#ticket/zoom/#{ticket.id}</a>
@ -2559,7 +2559,7 @@ class TicketTriggerRecursiveDisabledTest < ActiveSupport::TestCase
<br/>
<div><i><a href="https://zammad.com">Zammad</a>, your customer support system</i></div>',
'recipient' => 'ticket_customer',
'subject' => 'Thanks for your follow up (#{ticket.title})',
'subject' => 'Thanks for your follow-up (#{ticket.title})',
},
},
active: true,

View file

@ -658,7 +658,7 @@ class TicketTriggerTest < ActiveSupport::TestCase
)
Trigger.create!(
name: 'auto reply (on follow up of tickets)',
name: 'auto reply (on follow-up of tickets)',
condition: {
'ticket.action' => {
'operator' => 'is',
@ -679,7 +679,7 @@ class TicketTriggerTest < ActiveSupport::TestCase
},
perform: {
'notification.email' => {
'body' => '<p>Your follow up for (#{config.ticket_hook}##{ticket.number}) has been received and will be reviewed by our support staff.<p>
'body' => '<p>Your follow-up for (#{config.ticket_hook}##{ticket.number}) has been received and will be reviewed by our support staff.<p>
<br/>
<p>To provide additional information, please reply to this email or click on the following link:
<a href="#{config.http_type}://#{config.fqdn}/#ticket/zoom/#{ticket.id}">#{config.http_type}://#{config.fqdn}/#ticket/zoom/#{ticket.id}</a>
@ -687,7 +687,7 @@ class TicketTriggerTest < ActiveSupport::TestCase
<br/>
<p><i><a href="http://zammad.com">Zammad</a>, your customer support system</i></p>',
'recipient' => 'ticket_customer',
'subject' => 'Thanks for your follow up (#{ticket.title})',
'subject' => 'Thanks for your follow-up (#{ticket.title})',
},
},
active: true,
@ -807,7 +807,7 @@ class TicketTriggerTest < ActiveSupport::TestCase
assert_equal(6, ticket_p.articles.count, 'ticket_p.articles verify')
article_p = ticket_p.articles.last
assert_match('Thanks for your follow up (aaäöüßad asd)', article_p.subject)
assert_match('Thanks for your follow-up (aaäöüßad asd)', article_p.subject)
assert_match('Zammad <zammad@localhost>', article_p.from)
assert_no_match('config\.', article_p.body)
assert_match('http://zammad.example.com', article_p.body)
@ -838,7 +838,7 @@ class TicketTriggerTest < ActiveSupport::TestCase
assert_equal(8, ticket_p.articles.count, 'ticket_p.articles verify')
article_p = ticket_p.articles.last
assert_match('Thanks for your follow up (aaäöüßad asd)', article_p.subject)
assert_match('Thanks for your follow-up (aaäöüßad asd)', article_p.subject)
assert_match('Zammad <zammad@localhost>', article_p.from)
assert_no_match('config\.', article_p.body)
assert_match('http://zammad.example.com', article_p.body)
@ -2554,7 +2554,7 @@ class TicketTriggerTest < ActiveSupport::TestCase
updated_by_id: 1,
)
Trigger.create!(
name: 'auto reply (on follow up of tickets)',
name: 'auto reply (on follow-up of tickets)',
condition: {
'ticket.action' => {
'operator' => 'is',
@ -2575,7 +2575,7 @@ class TicketTriggerTest < ActiveSupport::TestCase
},
perform: {
'notification.email' => {
'body' => '<div>Your follow up for <b>(#{config.ticket_hook}#{ticket.number})</b> has been received and will be reviewed by our support staff.</div>
'body' => '<div>Your follow-up for <b>(#{config.ticket_hook}#{ticket.number})</b> has been received and will be reviewed by our support staff.</div>
<br/>
<div>To provide additional information, please reply to this email or click on the following link:
<a href="#{config.http_type}://#{config.fqdn}/#ticket/zoom/#{ticket.id}">#{config.http_type}://#{config.fqdn}/#ticket/zoom/#{ticket.id}</a>
@ -2585,7 +2585,7 @@ class TicketTriggerTest < ActiveSupport::TestCase
<br/>
<div><i><a href="https://zammad.com">Zammad</a>, your customer support system</i></div>',
'recipient' => 'ticket_customer',
'subject' => 'Thanks for your follow up (#{ticket.title})',
'subject' => 'Thanks for your follow-up (#{ticket.title})',
},
},
active: true,