Revision 4c9ae7fe
Von Moritz Bunkus vor mehr als 9 Jahren hinzugefügt
SL/SEPA.pm | ||
---|---|---|
364 | 364 |
|
365 | 365 |
my $query = |
366 | 366 |
qq|SELECT se.id, se.employee_id, se.executed, se.closed, itime::date AS export_date, |
367 |
(SELECT COUNT(*) |
|
368 |
FROM sepa_export_items sei |
|
369 |
WHERE (sei.sepa_export_id = se.id)) AS num_invoices, |
|
370 |
(SELECT SUM(sei.amount) |
|
371 |
FROM sepa_export_items sei |
|
372 |
WHERE (sei.sepa_export_id = se.id)) AS sum_amounts, |
|
367 | 373 |
e.name AS employee |
368 | 374 |
FROM sepa_export se |
369 | 375 |
LEFT JOIN ( |
bin/mozilla/sepa.pl | ||
---|---|---|
234 | 234 |
'employee' => { 'text' => $locale->text('Employee'), }, |
235 | 235 |
'executed' => { 'text' => $locale->text('Executed'), }, |
236 | 236 |
'closed' => { 'text' => $locale->text('Closed'), }, |
237 |
num_invoices => { 'text' => $locale->text('Number of invoices'), }, |
|
238 |
sum_amounts => { 'text' => $locale->text('Sum of all amounts'), }, |
|
237 | 239 |
); |
238 | 240 |
|
239 |
my @columns = qw(selected id export_date employee executed closed); |
|
241 |
my @columns = qw(selected id export_date employee executed closed invoices netamount); |
|
242 |
my %column_alignment = map { ($_ => 'right') } qw(num_invoices sum_amounts); |
|
240 | 243 |
|
241 | 244 |
foreach my $name (qw(id export_date employee executed closed)) { |
242 | 245 |
my $sortdir = $form->{sort} eq $name ? 1 - $form->{sortdir} : $form->{sortdir}; |
... | ... | |
246 | 249 |
$column_defs{selected}->{visible} = $open_available ? 'HTML' : 0; |
247 | 250 |
$column_defs{executed}->{visible} = $form->{l_executed} && $form->{l_not_executed} ? 1 : 0; |
248 | 251 |
$column_defs{closed}->{visible} = $form->{l_closed} && $form->{l_open} ? 1 : 0; |
252 |
$column_defs{$_}->{align} = $column_alignment{$_} for keys %column_alignment; |
|
249 | 253 |
|
250 | 254 |
my @options = (); |
251 | 255 |
push @options, ($vc eq 'customer' ? $::locale->text('Customer') : $locale->text('Vendor')) . ' : ' . $form->{f_vc} if ($form->{f_vc}); |
... | ... | |
278 | 282 |
my $edit_url = build_std_url('action=bank_transfer_edit', 'callback'); |
279 | 283 |
|
280 | 284 |
foreach my $export (@{ $exports }) { |
281 |
my $row = { map { $_ => { 'data' => $export->{$_} } } keys %{ $export } }; |
|
285 |
my $row = { map { $_ => { 'data' => $export->{$_}, 'align' => $column_alignment{$_} } } keys %{ $export } };
|
|
282 | 286 |
|
283 | 287 |
map { $row->{$_}->{data} = $export->{$_} ? $locale->text('yes') : $locale->text('no') } qw(executed closed); |
284 | 288 |
|
285 | 289 |
$row->{id}->{link} = $edit_url . '&id=' . E($export->{id}) . '&vc=' . E($vc); |
286 | 290 |
|
291 |
$row->{$_}->{data} = $::form->format_amount(\%::myconfig, $row->{$_}->{data}, 2) for qw(sum_amounts); |
|
292 |
|
|
287 | 293 |
if (!$export->{closed}) { |
288 | 294 |
$row->{selected}->{raw_data} = |
289 | 295 |
$cgi->hidden(-name => "exports[+].id", -value => $export->{id}) |
locale/de/all | ||
---|---|---|
1771 | 1771 |
'Number of columns of custom variables in form details (second row)' => 'Anzahl der Spalten für benutzerdef. Variablen in den Formulardetails (zweite Positionszeile)', |
1772 | 1772 |
'Number of copies' => 'Anzahl Kopien', |
1773 | 1773 |
'Number of entries changed: #1' => 'Anzahl geänderter Einträge: #1', |
1774 |
'Number of invoices' => 'Anzahl Rechnungen', |
|
1774 | 1775 |
'Number of invoices created:' => 'Anzahl erstellter Rechnungen:', |
1775 | 1776 |
'Number of invoices printed:' => 'Anzahl gedruckter Rechnungen:', |
1776 | 1777 |
'Number of invoices to create' => 'Anzahl zu erstellender Rechnungen', |
... | ... | |
2510 | 2511 |
'Sum for' => 'Summe für', |
2511 | 2512 |
'Sum for #1' => 'Summe für #1', |
2512 | 2513 |
'Sum for section' => 'Summe für Abschnitt', |
2514 |
'Sum of all amounts' => 'Summe aller Beträge', |
|
2513 | 2515 |
'Sum open amount' => 'Summierter offener Betrag', |
2514 | 2516 |
'Sum per' => 'Summe per', |
2515 | 2517 |
'Summen- und Saldenliste' => 'Summen- und Saldenliste', |
Auch abrufbar als: Unified diff
SEPA: In Exportliste Anzahl Rechnungen & Summe der Beträge als Spalten anzeigen