diff options
author | Mark Wells <mark@freeside.biz> | 2015-01-31 14:44:16 -0800 |
---|---|---|
committer | Mark Wells <mark@freeside.biz> | 2015-01-31 14:44:22 -0800 |
commit | f6abf4cd6d8e7a0121124e9394b5f28f5bc4daa5 (patch) | |
tree | db6264c4c2c38a423310d82d4443580607ecc82d /FS/FS/quotation.pm | |
parent | 3d796bf211374d941bda1116ee27a0543045ea8a (diff) |
discounts + quotations, #33099
Diffstat (limited to 'FS/FS/quotation.pm')
-rw-r--r-- | FS/FS/quotation.pm | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/FS/FS/quotation.pm b/FS/FS/quotation.pm index 5c94150..38e7318 100644 --- a/FS/FS/quotation.pm +++ b/FS/FS/quotation.pm @@ -631,6 +631,27 @@ sub search_sql_where { } +=item _items_pkg + +Return line item hashes for each package on this quotation. Differs from the +base L<FS::Template_Mixin> version in that it recalculates each quoted package +first, and doesn't implement the "condensed" option. + +=cut + +sub _items_pkg { + my ($self, %options) = @_; + my @quotation_pkg = $self->quotation_pkg; + foreach (@quotation_pkg) { + my $error = $_->estimate; + die "error calculating estimate for pkgpart " . $_->pkgpart.": $error\n" + if $error; + } + + # run it through the Template_Mixin engine + return $self->_items_cust_bill_pkg(\@quotation_pkg, %options); +} + =back =head1 BUGS |