X-Git-Url: http://wagnertech.de/gitweb/gitweb.cgi/mfinanz.git/blobdiff_plain/a34c05f386bc2abb45a097dcb4d68e8ab2f5af94..cd8b56f2ec945264132d443ad8f412699d1a8a1b:/SL/DB/PurchaseInvoice.pm diff --git a/SL/DB/PurchaseInvoice.pm b/SL/DB/PurchaseInvoice.pm index 19808eba5..ed0523bb4 100644 --- a/SL/DB/PurchaseInvoice.pm +++ b/SL/DB/PurchaseInvoice.pm @@ -8,6 +8,7 @@ use SL::DB::MetaSetup::PurchaseInvoice; use SL::DB::Manager::PurchaseInvoice; use SL::DB::Helper::AttrHTML; use SL::DB::Helper::LinkedRecords; +use SL::DB::Helper::Payment qw(:ALL); use SL::Locale::String qw(t8); # The calculator hasn't been adjusted for purchase invoices yet. @@ -80,6 +81,16 @@ sub abbreviation { return t8('Invoice (one letter abbreviation)'). '(' . t8('Storno (one letter abbreviation)') . ')' if $self->storno; return t8('Invoice (one letter abbreviation)'); +}; + +sub link { + my ($self) = @_; + + my $html; + $html = SL::Presenter->get->purchase_invoice($self, display => 'inline') if $self->invoice; + $html = SL::Presenter->get->ap_transaction($self, display => 'inline') if !$self->invoice; + + return $html; } 1;