Event Notifications: set sender for agent & customer notifi

Moderator: crythias

Post Reply
massimobianchi
Znuny newbie
Posts: 67
Joined: 02 Apr 2012, 12:18
Znuny Version: 3.1.14
Real Name: Massimo Bianchi
Company: NPO Sistemi S.p.A.
Contact:

Event Notifications: set sender for agent & customer notifi

Post by massimobianchi »

Hello,
we have the following scenario.

For some queues, i send a notification to customer and agent.

The customer notification obeys to "SenderAddress" bound to the queue, while agent notification is always from "OTRS Notification Master".

What I want to accomplish is to have
SendAgentNotification

behaving the same as

SendCustomerNotification

for the "From Address".

OTRS 3.1.x

Kind regards,
Massimo
Massimo Bianchi
skype: massimo.bianchi
OTRS:3.1.14, ITSM:3.1.8, httpd, mysql, Centos 6.3 on X86_64
jojo
Znuny guru
Posts: 15020
Joined: 26 Jan 2007, 14:50
Znuny Version: Git Master
Contact:

Re: Event Notifications: set sender for agent & customer not

Post by jojo »

not possible
"Production": OTRS™ 8, OTRS™ 7, STORM powered by OTRS
"Testing": ((OTRS Community Edition)) and git Master

Never change Defaults.pm! :: Blog
Professional Services:: http://www.otrs.com :: enjoy@otrs.com
massimobianchi
Znuny newbie
Posts: 67
Joined: 02 Apr 2012, 12:18
Znuny Version: 3.1.14
Real Name: Massimo Bianchi
Company: NPO Sistemi S.p.A.
Contact:

Re: Event Notifications: set sender for agent & customer not

Post by massimobianchi »

TO whom it might interest, I think I found an Hack.

Ispiration from file itself, just reasoned about CustomerNotification and AgentNotification.
Please keep in mind that my last line of program or shell scripting had been on hpux 10.30, some 10 years ago....

Modify EventNotification.pm

ORIGINAL

# send notification
if ( $Recipient{Type} eq 'Agent' ) {

# send notification
my $From = $Self->{ConfigObject}->Get('NotificationSenderName') . ' <'
. $Self->{ConfigObject}->Get('NotificationSenderEmail') . '>';

$Self->{SendmailObject}->Send(
From => $From,

MODIFIED

# send notification
if ( $Recipient{Type} eq 'Agent' ) {

# send notification
#my $From = $Self->{ConfigObject}->Get('NotificationSenderName') . ' <'
# . $Self->{ConfigObject}->Get('NotificationSenderEmail') . '>';

my %Address = $Self->{QueueObject}->GetSystemAddress( QueueID => $Article{QueueID} );
$Self->{SendmailObject}->Send(
#From => $From,
From => "$Address{RealName} <$Address{Email}>",
Massimo Bianchi
skype: massimo.bianchi
OTRS:3.1.14, ITSM:3.1.8, httpd, mysql, Centos 6.3 on X86_64
crythias
Moderator
Posts: 10169
Joined: 04 May 2010, 18:38
Znuny Version: 5.0.x
Location: SouthWest Florida, USA
Contact:

Re: Event Notifications: set sender for agent & customer not

Post by crythias »

Notifications come from the system. To send from a Queue use a reply or forward.
OTRS 6.0.x (private/testing/public) on Linux with MySQL database.
Please edit your signature to include your OTRS version, Operating System, and database type.
Click Subscribe Topic below to get notifications. Consider amending your topic title to include [SOLVED] if it is so.
Need help? Before you ask
massimobianchi
Znuny newbie
Posts: 67
Joined: 02 Apr 2012, 12:18
Znuny Version: 3.1.14
Real Name: Massimo Bianchi
Company: NPO Sistemi S.p.A.
Contact:

Re: Event Notifications: set sender for agent & customer not

Post by massimobianchi »

Well. It works.
Massimo Bianchi
skype: massimo.bianchi
OTRS:3.1.14, ITSM:3.1.8, httpd, mysql, Centos 6.3 on X86_64
cryptoroot
Znuny newbie
Posts: 26
Joined: 10 Jul 2014, 19:58
Znuny Version: 4.0.3
Real Name: Jorge Rojas
Company: Instituto Costarricense de Electricidad
Location: Costa Rica

Re: Event Notifications: set sender for agent & customer not

Post by cryptoroot »

massimobianchi wrote:TO whom it might interest, I think I found an Hack.

Ispiration from file itself, just reasoned about CustomerNotification and AgentNotification.
Please keep in mind that my last line of program or shell scripting had been on hpux 10.30, some 10 years ago....

Modify EventNotification.pm

ORIGINAL

# send notification...
Great modification massimo!, this resolve an old request and works well in 3.3.9. Thanks
Post Reply