[rt-devel] simple custom Action gives Mason compiler error

a.smith at ldex.co.uk a.smith at ldex.co.uk
Fri Mar 27 13:50:49 EDT 2015


 

its a bit dead on here!

In case this helps anyone I eventually got
this working after lots of trial and error:

package
RT::Action::QChange;

use strict;
use warnings;

use base
qw(RT::Action::Notify);

use Email::Address;

sub Prepare {
 my $self =
shift;

 return 1;
}

my $self;

sub Commit {

 my $self = shift;

my
$argument = $self->Argument;
 unless ( $argument ) {

$RT::Logger->error("Argument is mandatory for Test action");
 return 0;

}

 my ($status, $msg) = $self->TicketObj->SetQueue("$argument");
 if (
not $status ) {
 RT::Logger->error("Could not reassign queue: $msg");

return 0;
 }

 RT::Base->_ImportOverlays();

 return 1;
}

1;

 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.bestpractical.com/pipermail/rt-devel/attachments/20150327/df6ea386/attachment.html>


More information about the rt-devel mailing list