diff options
author | Mark Wells <mark@freeside.biz> | 2014-01-07 11:48:58 -0800 |
---|---|---|
committer | Mark Wells <mark@freeside.biz> | 2014-01-07 11:48:58 -0800 |
commit | 77783e2521b98f0ca76ebe953873fbdc7cc51e98 (patch) | |
tree | 3adc6860bf07ffdf8ff095c60f3074c1b52cd126 /FS/FS/cust_event.pm | |
parent | e08dc441d98b98643d5108ce8c189fcf12693e0c (diff) |
correctly pass arguments when manually re-emailing/printing invoices, #26076
Diffstat (limited to 'FS/FS/cust_event.pm')
-rw-r--r-- | FS/FS/cust_event.pm | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/FS/FS/cust_event.pm b/FS/FS/cust_event.pm index 6a67c08..78d4217 100644 --- a/FS/FS/cust_event.pm +++ b/FS/FS/cust_event.pm @@ -479,9 +479,15 @@ sub re_X { my $cust_X = $cust_event->cust_X; # cust_bill next unless $cust_X->can($method); - $cust_X->$method( $cust_event->part_event->templatename - || $cust_X->agent_template - ); + my $part_event = $cust_event->part_event; + my $template = $part_event->templatename + || $cust_X->agent_template; + my $modenum = $part_event->option('modenum') || ''; + my $invoice_from = $part_event->option('agent_invoice_from') || ''; + $cust_X->set('mode' => $modenum); + $cust_X->$method( { template => $template, + modenum => $modenum, + invoice_from => $invoice_from } ); if ( $job ) { #progressbar foo $num++; |