In case of web form, use also email in from to be able to reply.
This commit is contained in:
parent
03fed96634
commit
1794b98362
1 changed files with 5 additions and 1 deletions
|
@ -24,7 +24,11 @@ class Observer::Ticket::Article::FillupFromGeneral < ActiveRecord::Observer
|
|||
return if type['name'] == 'facebook feed comment'
|
||||
|
||||
return if !record.created_by_id
|
||||
user = User.find(record.created_by_id)
|
||||
user = User.find(record.created_by_id)
|
||||
if type.name == 'web'
|
||||
record.from = "#{user.firstname} #{user.lastname} <#{user.email}>"
|
||||
return
|
||||
end
|
||||
record.from = "#{user.firstname} #{user.lastname}"
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue