Projekt

Allgemein

Profil

« Zurück | Weiter » 

Revision 0e1c16fd

Von Sven Schöling vor etwa 8 Jahren hinzugefügt

  • ID 0e1c16fdec22180f47a298a9d1d9e3d26ab821ca
  • Vorgänger 5975ee07
  • Nachfolger 470cd722

GDPDU: taxdescription und Übersetzungen

Unterschiede anzeigen:

SL/GDPDU.pm
49 49
  name              => { type => 'Rose::DB::Object::Metadata::Column::Text',    text => t8('Name'), },
50 50
  notes             => { type => 'Rose::DB::Object::Metadata::Column::Text',    text => t8('Notes'), },
51 51
  tax               => { type => 'Rose::DB::Object::Metadata::Column::Text',    text => t8('Tax'), },
52
  taxdescription    => { type => 'Rose::DB::Object::Metadata::Column::Text',    text => t8('tax_taxdescription'), },
52 53
  taxkey            => { type => 'Rose::DB::Object::Metadata::Column::Integer', text => t8('Taxkey'), },
53 54
  tax_accname       => { type => 'Rose::DB::Object::Metadata::Column::Text',    text => t8('Tax Account Name'), },
54 55
  tax_accno         => { type => 'Rose::DB::Object::Metadata::Column::Text',    text => t8('Tax Account'), },
55 56
  transdate         => { type => 'Rose::DB::Object::Metadata::Column::Date',    text => t8('Invoice Date'), },
56 57
  vcnumber          => { type => 'Rose::DB::Object::Metadata::Column::Text',    text => t8('Customer/Vendor Number'), },
57
  customer_id       => { type => 'Rose::DB::Object::Metadata::Column::Integer', text => t8('Customer ID'), },
58
  vendor_id         => { type => 'Rose::DB::Object::Metadata::Column::Integer', text => t8('Vendor ID'), },
58
  customer_id       => { type => 'Rose::DB::Object::Metadata::Column::Integer', text => t8('Customer (database ID)'), },
59
  vendor_id         => { type => 'Rose::DB::Object::Metadata::Column::Integer', text => t8('Vendor (database ID)'), },
59 60
);
60 61

  
61 62
my @datev_columns = qw(
......
65 66
  transdate    invnumber      amount
66 67
  debit_accno  debit_accname
67 68
  credit_accno credit_accname
68
  tax
69
  taxdescription tax
69 70
  tax_accno    tax_accname    taxkey
70 71
  notes
71 72
);
......
324 325
sub datev_columns {
325 326
  my ($self, $table) = @_;
326 327

  
327
  my %cols_by_primary_key = partition_by { $datev_column_defs{$_}{primary_key} } @datev_columns;
328
  my %cols_by_primary_key = partition_by { 1 * $datev_column_defs{$_}{primary_key} } @datev_columns;
328 329
  $::lxdebug->dump(0,  "cols", \%cols_by_primary_key);
329 330

  
330 331
  for my $column (@{ $cols_by_primary_key{1} }) {
......
338 339
    })
339 340
  }
340 341

  
341
  for my $column (@{ $cols_by_primary_key{''} }) {
342
  for my $column (@{ $cols_by_primary_key{0} }) {
342 343
    my $type = $column_types{ $datev_column_defs{$column}{type} };
343 344

  
344 345
    die "unknown col type @{[ ref $column]}" unless $type;
......
413 414
      credit_accno     => $haben->{accno},
414 415
      credit_accname   => $haben->{accname},
415 416
      tax              => defined $amount->{net_amount} ? abs($amount->{amount}) - abs($amount->{net_amount}) : 0,
417
      taxdescription   => defined($soll->{tax_accno}) ? $soll->{taxdescription} : $haben->{taxdescription},
416 418
      notes            => $haben->{notes},
417 419
      (map { ($_ => $tax->{$_})                    } qw(taxkey tax_accname tax_accno)),
418 420
      (map { ($_ => ($haben->{$_} // $soll->{$_})) } qw(acc_trans_id invnumber name vcnumber transdate)),

Auch abrufbar als: Unified diff