Revision 0abce1b8
Von Kivitendo Admin vor fast 8 Jahren hinzugefügt
SL/DB/GLTransaction.pm | ||
---|---|---|
4 | 4 |
|
5 | 5 |
use SL::DB::MetaSetup::GLTransaction; |
6 | 6 |
use SL::Locale::String qw(t8); |
7 |
use List::Util qw(sum); |
|
7 | 8 |
|
8 | 9 |
# Creates get_all, get_all_count, get_all_iterator, delete_all and update_all. |
9 | 10 |
__PACKAGE__->meta->make_manager_class; |
... | ... | |
36 | 37 |
|
37 | 38 |
sub oneline_summary { |
38 | 39 |
my ($self) = @_; |
39 |
return sprintf("%s: %s %s (%s)", $self->abbreviation, $self->description, $self->reference, $_->transdate->to_kivitendo); |
|
40 |
my $amount = sum map { $_->amount if $_->amount > 0 } @{$self->transactions}; |
|
41 |
$amount = $::form->format_amount(\%::myconfig, $amount, 2); |
|
42 |
return sprintf("%s: %s %s %s (%s)", $self->abbreviation, $self->description, $self->reference, $amount, $self->transdate->to_kivitendo); |
|
40 | 43 |
} |
41 | 44 |
|
42 | 45 |
sub link { |
SL/DB/Invoice.pm | ||
---|---|---|
558 | 558 |
sub oneline_summary { |
559 | 559 |
my $self = shift; |
560 | 560 |
|
561 |
return sprintf("%s: %s %s (%s)", $self->abbreviation, $self->invnumber, $self->customer->name, $self->transdate->to_kivitendo); |
|
561 |
return sprintf("%s: %s %s %s (%s)", $self->abbreviation, $self->invnumber, $self->customer->name, |
|
562 |
$::form->format_amount(\%::myconfig, $self->amount,2), $self->transdate->to_kivitendo); |
|
562 | 563 |
} |
563 | 564 |
|
564 | 565 |
sub date { |
SL/DB/PurchaseInvoice.pm | ||
---|---|---|
91 | 91 |
sub oneline_summary { |
92 | 92 |
my $self = shift; |
93 | 93 |
|
94 |
return sprintf("%s: %s %s (%s)", $self->abbreviation, $self->invnumber, $self->vendor->name, $self->transdate->to_kivitendo); |
|
94 |
return sprintf("%s: %s %s %s (%s)", $self->abbreviation, $self->invnumber, $self->vendor->name, |
|
95 |
$::form->format_amount(\%::myconfig, $self->amount,2), $self->transdate->to_kivitendo); |
|
95 | 96 |
} |
96 | 97 |
|
97 | 98 |
sub link { |
Auch abrufbar als: Unified diff
oneline_summary mit Rechnungsbeträgen
Bei Belegen wird der Bruttobetrag angezeigt.
Bei Dialogbuchungen wird die Summe aller Haben-Buchungen als Betrag
angezeigt.