[freeside-commits] freeside/FS/FS/part_export status_shellcommands.pm, 1.1.2.2, 1.1.2.3
Ivan,,,
ivan at wavetail.420.am
Thu Feb 9 02:44:25 PST 2012
Update of /home/cvs/cvsroot/freeside/FS/FS/part_export
In directory wavetail.420.am:/tmp/cvs-serv1401
Modified Files:
Tag: FREESIDE_2_3_BRANCH
status_shellcommands.pm
Log Message:
spam settings, RT#15987
Index: status_shellcommands.pm
===================================================================
RCS file: /home/cvs/cvsroot/freeside/FS/FS/part_export/status_shellcommands.pm,v
retrieving revision 1.1.2.2
retrieving revision 1.1.2.3
diff -u -w -d -r1.1.2.2 -r1.1.2.3
--- status_shellcommands.pm 9 Feb 2012 08:39:24 -0000 1.1.2.2
+++ status_shellcommands.pm 9 Feb 2012 10:44:23 -0000 1.1.2.3
@@ -3,6 +3,7 @@
use vars qw( %info );
use Tie::IxHash;
+use String::ShellQuote;
tie my %options, 'Tie::IxHash',
'user' => { label=>'Remote username', default=>'root' },
@@ -38,10 +39,31 @@
sub export_setstatus {
my($self, $svc_acct, $hashref) = @_;
- $self->_export_command('spam_enable', $svc_acct->email);
+ my @shellargs = (
+ $svc_acct->svcnum,
+ user => $self->option('user') || 'root',
+ host => $self->machine,
+ #stdin_string => $stdin_string,
+ ignore_all_output => $self->option('ignore_all_output'),
+ #ignored_errors => $self->option('ignored_errors') || '',
+ );
- $self->_export_command('spam_tag2_level', $svc_acct->email, $hashref->{'spam_tag2_level'} );
- $self->_export_command('spam_kill_level', $svc_acct->email, $hashref->{'spam_kill_level'} );
+ $self->shellcommands_queue( @shallargs, 'command' =>
+ $self->option('spam_enable'). ' '.
+ shell_quote($svc_acct->email)
+ );
+
+ $self->shellcommands_queue( @shallargs, 'command' =>
+ $self->option('spam_tag2_level'). ' '.
+ shell_quote($svc_acct->email). ' '.
+ $hashref->{'spam_tag2_level'}
+ );
+
+ $self->shellcommands_queue( @shallargs, 'command' =>
+ $self->option('spam_kill_level'). ' '.
+ shell_quote($svc_acct->email). ' '.
+ $hashref->{'spam_kill_level'}
+ );
}
More information about the freeside-commits
mailing list