diff options
author | ivan <ivan> | 2005-06-02 09:29:56 +0000 |
---|---|---|
committer | ivan <ivan> | 2005-06-02 09:29:56 +0000 |
commit | 684a478c0f88e5bf6d1d3f32f4618089146b5709 (patch) | |
tree | 1f0c8e23048aa20e872ff10f07a134436968ac43 /FS/FS/part_bill_event.pm | |
parent | 14cc10e34e277f4761be76d67d621b5a5d10a87f (diff) |
add ability to search on a date range of invoice events and then reprint or reemail (boy was that a bit more work than i expected), closes: Bug#946
Diffstat (limited to 'FS/FS/part_bill_event.pm')
-rw-r--r-- | FS/FS/part_bill_event.pm | 23 |
1 files changed, 22 insertions, 1 deletions
diff --git a/FS/FS/part_bill_event.pm b/FS/FS/part_bill_event.pm index b7c8b6a..0d03ebf 100644 --- a/FS/FS/part_bill_event.pm +++ b/FS/FS/part_bill_event.pm @@ -171,11 +171,32 @@ sub check { $self->SUPER::check; } +=item templatename + +Returns the alternate invoice template name, if any, or false if there is +no alternate template for this invoice event. + +=cut + +sub templatename { + my $self = shift; + if ( $self->plan =~ /^send_(alternate|agent)$/ + && $self->plandata =~ /^(agent_)?templatename (.*)$/m + ) + { + $2; + } else { + ''; + } +} + + =back =head1 BUGS -Alas. +The whole "eventcode" idea is bunk. This should be refactored with subclasses +like part_pkg/ and part_export/ =head1 SEE ALSO |