Projekt

Allgemein

Profil

« Zurück | Weiter » 

Revision c97e6606

Von Kivitendo Admin vor 11 Monaten hinzugefügt

  • ID c97e66068381b8126fe3386a03386954476382fb
  • Vorgänger 3c3fee44
  • Nachfolger a040bb8d

Neues Feature SEPA-Geldtransitkonto

Für die Verbuchung von SEPA-Zahlläufen über ein Geldtransitkonto.
Siehe changelog.

Unterschiede anzeigen:

SL/DB/MetaSetup/Default.pm
197 197
  sepa_set_duedate_as_default_exec_date     => { type => 'boolean', default => 'false' },
198 198
  sepa_set_skonto_date_as_default_exec_date => { type => 'boolean', default => 'false' },
199 199
  sepa_set_skonto_date_buffer_in_days       => { type => 'integer', default => '0' },
200
  sepa_transfer_chart_id                    => { type => 'integer' },
200 201
  servicenumber                             => { type => 'text' },
201 202
  shipped_qty_require_stock_out             => { type => 'boolean', default => 'false', not_null => 1 },
202 203
  show_bestbefore                           => { type => 'boolean', default => 'false' },
......
298 299
    key_columns => { requirement_spec_section_order_part_id => 'id' },
299 300
  },
300 301

  
302
  sepa_transfer_chart => {
303
    class       => 'SL::DB::Chart',
304
    key_columns => { sepa_transfer_chart_id => 'id' },
305
  },
306

  
301 307
  stocktaking_bin => {
302 308
    class       => 'SL::DB::Bin',
303 309
    key_columns => { stocktaking_bin_id => 'id' },
SL/SEPA.pm
513 513
      die "sepa_export_item needs either ar_id or ap_id\n";
514 514
    };
515 515

  
516
    # override the chart_id if sepa_transfer_chart_id is set
517
    my $payment_chart_id = $params{sepa_transfer_chart_id} ? $params{sepa_transfer_chart_id}
518
                                                           : $sepa_export_item->chart_id;
519

  
516 520
    $invoice->pay_invoice(amount       => $sepa_export_item->amount,
517 521
                          payment_type => $sepa_export_item->payment_type,
518
                          chart_id     => $sepa_export_item->chart_id,
522
                          chart_id     => $payment_chart_id,
519 523
                          source       => $sepa_export_item->reference,
520 524
                          transdate    => $item->{execution_date},  # value from user form
521 525
                         );
bin/mozilla/sepa.pl
344 344
  my $locale = $main::locale;
345 345
  my $vc     = $form->{vc} eq 'customer' ? 'customer' : 'vendor';
346 346

  
347
  my $defaults = SL::DB::Default->get;
348

  
349
  $::request->layout->add_javascripts("autocomplete_chart.js");
350

  
347 351
  my @ids    = ();
348 352
  if (!$form->{mode} || ($form->{mode} eq 'single')) {
349 353
    push @ids, $form->{id};
......
397 401
                                     export                    => $export,
398 402
                                     current_date              => $form->current_date(\%main::myconfig),
399 403
                                     show_post_payments_button => $show_post_payments_button,
404
                                     sepa_transfer_chart_id    => $defaults->sepa_transfer_chart_id,
400 405
                                   });
401 406

  
402 407
  $main::lxdebug->leave_sub();
......
434 439
    $form->show_generic_error($locale->text('You have to specify an execution date for each antry.'));
435 440
  }
436 441

  
437
  SL::SEPA->post_payment('items' => \@items_to_post, vc => $vc);
442
  my $sepa_transfer_chart_id;
443

  
444
  if ( $form->{sepa_transfer_chart_id} ) {
445
    my $chart = SL::DB::Chart->new(id => $form->{sepa_transfer_chart_id})->load;
446
    $sepa_transfer_chart_id = $chart->id if $chart;
447
  }
448

  
449
  SL::SEPA->post_payment('items' => \@items_to_post, vc => $vc, sepa_transfer_chart_id => $sepa_transfer_chart_id);
438 450

  
439 451
  $form->show_generic_information($locale->text('The payments have been posted.'));
440 452

  
locale/de/all
1951 1951
  'If item not found, allow creation of new item' => 'Falls Artikel nicht gefunden, erlaube Erfassen eines Neuen',
1952 1952
  'If left empty the default sender from the kivitendo configuration will be used (key \'email_from\' in section \'periodic_invoices\'; current value: #1).' => 'Falls leer, so wird der Standardabsender aus der kivitendo-Konfiguration genutzt (Schlüssel »email_from« in Abschnitt »periodic_invoices«; aktueller Wert: #1).',
1953 1953
  'If missing then the start date will be used.' => 'Falls es fehlt, so wird die erste Rechnung für das Startdatum erzeugt.',
1954
  'If no money transit account is selected then the SEPA bank account will be booked directly.' => 'Wenn kein Geldtransitkonto ausgewählt ist wird das SEPA Bankkonto direkt bebucht.',
1954 1955
  'If one or more space separated serial numbers are assigned in a sales invoice, match the charge number of the inventory item. Assumes that Serial Number and Charge Number have 1:1 relation. Otherwise throw a error message for the default sales invoice transfer.' => 'Falls eine oder mehrere Leerzeichen separierte Seriennummern in Verkaufsrechnungen definiert sind, nutz diese als Chargennummern fürs Standard-Auslagern über Rechnung. Seriennummern und eingelagerte Chargen kommen jeweils exakt nur einmal vor. Falls die Chargennummer oder das Mengenverhältnis (1:1) in keinem Lagerort existiert wird eine Fehlermeldung beim Auslagern generiert.',
1955 1956
  'If searching a part from a document and no part is found then offer to create a new part.' => 'Wenn bei der Artikelsuche aus einem Dokument heraus kein Artikel gefunden wird, dann wird ermöglicht, von dort aus einen neuen Artikel anzulegen.',
1956 1957
  'If set to no the \'delivery date\' field for sales orders won\'t be set at all.' => 'Falls der Wert auf Nein gesetzt wird, wird überhaupt kein Lieferdatum in Verkaufsaufträgen gesetzt',
......
1964 1965
  'If the test mode is enabled, the Factur-X/ZUGFeRD invoices will be flagged so that they\'re only fit to be used for testing purposes.' => 'Wenn der Testmodus aktiviert ist, werden Factur-X-/ZUGFeRD-Rechnungen so markiert, dass sie nur für Testzwecke dienen dürfen.',
1965 1966
  'If this option is disabled, the bank import is not possible for this account anymore. In the case of invoices and accounts payable and receivable entries, incoming and outgoing payments can then be posted directly to the account manually.' => 'Wenn diese Option deaktiviert ist, ist der Bankimport für dieses Konto gesperrt. Bei Rechnungen sowie Kreditoren- und Debitorenbuchungen können dann direkt Zahlungsein- bzw. ausgänge manuell auf das Konto verbucht werden.',
1966 1967
  'If yes, delivery order positions are considered "delivered" only if they have been stocked out of the inventory. Otherwise saving the delivery order is considered delivered.' => 'Wenn diese Option aktiviert ist, gelten Lieferscheinpositionen nur dann als geliefert wenn sie im Lieferschein ausgelagert wurden, und die Ware aus dem Lager ausgebucht wurde. Andernfalls gilt das Speichern des Lieferscheins als Lieferung.',
1968
  'If you choose a money transit account here, this account will be used for booking the payment, rather than the actual bank account. The intermediary money transit account then needs to be reconciled manually once the actual bank statements are available.' => 'Wenn Sie hier eine Geldtransitkonto auswählen wird dieses Konto für die Verbuchung der Zahlung verwendet, und nicht das SEPA Bankkonto. Das Geldtransitkonto muß dann händisch mit dem Bankkonto verrechnet werden, sobald die tatsächlichen Bankbelege vorliegen.',
1967 1969
  'If you enter values for the part number and / or part description then only those bins containing parts whose part number or part description match your input will be shown.' => 'Wenn Sie für die Artikelnummer und / oder die Beschreibung etwas eingeben, so werden nur die Lagerplätze angezeigt, in denen Waren eingelagert sind, die Ihre Suchbegriffe enthalten.',
1968 1970
  'If you have not chosen for example the category revenue for a tax and you choose an revenue account to create a transfer in the general ledger, this tax will not be displayed in the tax dropdown.' => 'Wenn Sie z.B. die Kategory Erlös für eine Steuer nicht gewählt haben und ein Erlöskonto beim Erstellen einer Dialogbuchung wählen, wird diese Steuer auch nicht im Dropdown-Menü für die Steuern angezeigt.',
1969 1971
  'If you lock the system normal users won\'t be able to log in.' => 'Wenn Sie das System sperren, so werden sich normale Benutzer nicht mehr anmelden können.',
......
2370 2372
  'Mon'                         => 'Mo',
2371 2373
  'Monat'                       => 'Monat',
2372 2374
  'Monday'                      => 'Montag',
2375
  'Money transit account'       => 'Geldtransitkonto',
2373 2376
  'Month'                       => 'Monat',
2374 2377
  'Month/Year'                  => 'Monat/Jahr',
2375 2378
  'Monthly'                     => 'monatlich',
......
3295 3298
  'SEPA message ID'             => 'SEPA-Nachrichten-ID',
3296 3299
  'SEPA message IDs'            => 'SEPA-Nachrichten-IDs',
3297 3300
  'SEPA strings'                => 'SEPA-Überweisungen',
3301
  'SEPA transfer account'       => 'SEPA Geldtransitkonto',
3298 3302
  'SQL query'                   => 'SQL-Abfrage',
3299 3303
  'SWIFT MT940 format'          => 'SWIFT-MT940-Format',
3300 3304
  'Saldo Credit'                => 'Saldo Haben',
locale/en/all
1946 1946
  'If item not found, allow creation of new item' => '',
1947 1947
  'If left empty the default sender from the kivitendo configuration will be used (key \'email_from\' in section \'periodic_invoices\'; current value: #1).' => '',
1948 1948
  'If missing then the start date will be used.' => '',
1949
  'If no money transit account is selected then the SEPA bank account will be booked directly.' => '',
1949 1950
  'If one or more space separated serial numbers are assigned in a sales invoice, match the charge number of the inventory item. Assumes that Serial Number and Charge Number have 1:1 relation. Otherwise throw a error message for the default sales invoice transfer.' => '',
1950 1951
  'If searching a part from a document and no part is found then offer to create a new part.' => '',
1951 1952
  'If set to no the \'delivery date\' field for sales orders won\'t be set at all.' => '',
......
1959 1960
  'If the test mode is enabled, the Factur-X/ZUGFeRD invoices will be flagged so that they\'re only fit to be used for testing purposes.' => '',
1960 1961
  'If this option is disabled, the bank import is not possible for this account anymore. In the case of invoices and accounts payable and receivable entries, incoming and outgoing payments can then be posted directly to the account manually.' => '',
1961 1962
  'If yes, delivery order positions are considered "delivered" only if they have been stocked out of the inventory. Otherwise saving the delivery order is considered delivered.' => '',
1963
  'If you choose a money transit account here, this account will be used for booking the payment, rather than the actual bank account. The intermediary money transit account then needs to be reconciled manually once the actual bank statements are available.' => '',
1962 1964
  'If you enter values for the part number and / or part description then only those bins containing parts whose part number or part description match your input will be shown.' => '',
1963 1965
  'If you have not chosen for example the category revenue for a tax and you choose an revenue account to create a transfer in the general ledger, this tax will not be displayed in the tax dropdown.' => '',
1964 1966
  'If you lock the system normal users won\'t be able to log in.' => '',
......
2365 2367
  'Mon'                         => '',
2366 2368
  'Monat'                       => '',
2367 2369
  'Monday'                      => '',
2370
  'Money transit account'       => '',
2368 2371
  'Month'                       => '',
2369 2372
  'Month/Year'                  => '',
2370 2373
  'Monthly'                     => '',
......
3292 3295
  'SEPA message ID'             => '',
3293 3296
  'SEPA message IDs'            => '',
3294 3297
  'SEPA strings'                => '',
3298
  'SEPA transfer account'       => '',
3295 3299
  'SQL query'                   => '',
3296 3300
  'SWIFT MT940 format'          => '',
3297 3301
  'Saldo Credit'                => '',
sql/Pg-upgrade2/sepa_transfer_chart.sql
1
-- @tag: sepa_transfer_chart
2
-- @description: Für SEPA-Überweisungen ein Zwischenkonto konfigurierbar machen
3
-- @depends: release_3_8_0
4

  
5
ALTER TABLE defaults ADD COLUMN sepa_transfer_chart_id INTEGER REFERENCES chart(id);
templates/design40_webpages/client_config/_default_accounts.html
61 61
      <th>[% LxERP.t8("Account for workflow from purchase order to ap transaction") %]</th>
62 62
      <td>[% P.chart.picker('defaults.workflow_po_ap_chart_id', SELF.defaults.workflow_po_ap_chart_id, type='AP_amount', choose=1, style=style) %]</td>
63 63
    </tr>
64
    <tr>
65
      <th>[% LxERP.t8("SEPA transfer account") %]</th>
66
      <td>[% P.chart.picker('defaults.sepa_transfer_chart_id', SELF.defaults.sepa_transfer_chart_id, type='AP_paid,AR_paid', choose=1, style=style) %]<td>
67
    </tr>
64 68
  </tbody>
65 69
</table>
66 70

  
templates/webpages/client_config/_default_accounts.html
65 65
   <td>[% P.chart.picker('defaults.workflow_po_ap_chart_id', SELF.defaults.workflow_po_ap_chart_id, type='AP_amount', choose=1, style=style) %]<td>
66 66
  </tr>
67 67

  
68
  <tr>
69
   <td align="right">[% LxERP.t8("SEPA transfer account") %]</td>
70
   <td>[% P.chart.picker('defaults.sepa_transfer_chart_id', SELF.defaults.sepa_transfer_chart_id, type='AP_paid,AR_paid', choose=1, style=style) %]<td>
71
  </tr>
72

  
68 73
  <tr>
69 74
    <th align="right">[% LxERP.t8("Year-end closing") %]</th>
70 75
  </tr>
templates/webpages/sepa/bank_transfer_edit.html
2 2
[% USE HTML %]
3 3
[% USE LxERP %]
4 4
[%- USE L %]
5
[%- USE P %]
5 6
[% IF vc == 'vendor' %]
6 7
 [% SET is_vendor = 1 %]
7 8
 [% SET arap = 'ap' %]
......
14 15
<h1>[% title %]: [% HTML.escape(export.ids.join(', ')) %]</h1>
15 16

  
16 17
 <form action="sepa.pl" method="post" id="form">
18

  
19
  [% IF vc == 'vendor' %]
20
  <p>
21
  <table>
22
  <tr>
23
  <td>
24
  [% 'Money transit account' | $T8 %]:
25
  </td>
26
  <td>
27
  [% P.chart.picker('sepa_transfer_chart_id', sepa_transfer_chart_id, type='AP_paid,AR_paid', choose=1) %]
28
  </td>
29
  <td>
30
  [% 'If you choose a money transit account here, this account will be used for booking the payment, rather than the actual bank account. The intermediary money transit account then needs to be reconciled manually once the actual bank statements are available.' | $T8 %]<br>
31
  [% 'If no money transit account is selected then the SEPA bank account will be booked directly.' | $T8 %]<br>
32
  </td>
33
  </tr>
34
  </table>
35
  </p>
36
  [% END %]
37

  
17 38
  <p>
18 39
   <table>
19 40
    <tr>

Auch abrufbar als: Unified diff