Projekt

Allgemein

Profil

« Zurück | Weiter » 

Revision 796eb00b

Von Cem Aydin vor mehr als 1 Jahr hinzugefügt

  • ID 796eb00b78ae3b52032775f2a78754f9ecb98c52
  • Vorgänger 60a6b5df
  • Nachfolger 5bea4164

Bankkonto für die Nutzung mit dem Bankimport markieren

Bei den Bankkonten Auswahlmöglichkeit hinzugefügt, ob das Konto für den Bankimport verwendet werden soll.
(Standardwert und bestehende: Ja)
Notwendig, da es sein kann, dass Bankkonten für die QR-Rechnung aber nicht für den Bankimport genutzt werden. In dem Fall muss manuelles Buchen weiterhin möglich sein.

Unterschiede anzeigen:

SL/Controller/CsvImport/BankTransaction.pm
168 168
    $object->local_bank_account_id($bank_account->id);
169 169
    $entry->{info_data}->{local_bank_name} = $bank_account->name;
170 170
  }
171

  
172
  # Check if local bank account is marked for bank import
173
  if ($object->local_bank_account_id && !$self->bank_accounts_by->{id}->{ $object->local_bank_account_id }->use_with_bank_import) {
174
    push @{ $entry->{errors} }, $::locale->text('Error: local bank account is not marked for bank import, check settings under System -> Bank Accounts');
175
    return 0;
176
  }
177

  
171 178
  return $object->local_bank_account_id ? 1 : 0;
172 179
}
173 180

  
SL/Controller/SimpleSystemSetting.pm
36 36
      { method => 'bank_code',                                 title => t8('Bank code'), },
37 37
      { method => 'bank_account_id',                           title => t8('Bank Account Id Number (Swiss)'), },
38 38
      { method => 'bic',                                       title => t8('BIC'), },
39
      {                                                        title => t8('Use with bank import'), formatter => sub { $_[0]->use_with_bank_import ? t8('yes') : t8('no') } },
39 40
      {                                                        title => t8('Use for Factur-X/ZUGFeRD'), formatter => sub { $_[0]->use_for_zugferd ? t8('yes') : t8('no') } },
40 41
      {                                                        title => t8('Use for Swiss QR-Bill'), formatter => sub { $_[0]->use_for_qrbill ? t8('yes') : t8('no') } },
41 42
      { method => 'reconciliation_starting_date_as_date',      title => t8('Date'),    align => 'right' },
bin/mozilla/ap.pl
438 438
  my (%charts, %bank_accounts);
439 439
  my $default_ap_amount_chart_id;
440 440
  # don't add manual bookings for charts which are assigned to real bank accounts
441
  # and are flagged for use with bank import
441 442
  my $bank_accounts = SL::DB::Manager::BankAccount->get_all();
442 443
  foreach my $bank (@{ $bank_accounts }) {
443
    my $accno_paid_bank = $bank->chart->accno;
444
    $bank_accounts{$accno_paid_bank} = 1;
444
    if ($bank->use_with_bank_import) {
445
      my $accno_paid_bank = $bank->chart->accno;
446
      $bank_accounts{$accno_paid_bank} = 1;
447
    }
445 448
  }
446 449

  
447 450
  foreach my $item (@{ $form->{ALL_CHARTS} }) {
bin/mozilla/ar.pl
412 412
  my (@AR_paid_values, %AR_paid_labels, %bank_accounts);
413 413
  my $default_ar_amount_chart_id;
414 414
  # don't add manual bookings for charts which are assigned to real bank accounts
415
  # and are flagged for use with bank import
415 416
  my $bank_accounts = SL::DB::Manager::BankAccount->get_all();
416 417
  foreach my $bank (@{ $bank_accounts }) {
417
    my $accno_paid_bank = $bank->chart->accno;
418
    $bank_accounts{$accno_paid_bank} = 1;
418
    if ($bank->use_with_bank_import) {
419
      my $accno_paid_bank = $bank->chart->accno;
420
      $bank_accounts{$accno_paid_bank} = 1;
421
    }
419 422
  }
420 423
  foreach my $item (@{ $form->{ALL_CHARTS} }) {
421 424
    if ($item->{link_split}{AR_amount}) {
bin/mozilla/ir.pl
618 618
      $form->{"changeable_$i"} = 0;
619 619
    }
620 620
    # don't add manual bookings for charts which are assigned to real bank accounts
621
    # and are flagged for use with bank import
621 622
    my $bank_accounts = SL::DB::Manager::BankAccount->get_all();
622 623
    foreach my $bank (@{ $bank_accounts }) {
623
      my $accno_paid_bank = $bank->chart->accno;
624
      $form->{selectAP_paid} =~ s/<option>$accno_paid_bank--(.*?)<\/option>//;
624
      if ($bank->use_with_bank_import) {
625
        my $accno_paid_bank = $bank->chart->accno;
626
        $form->{selectAP_paid} =~ s/<option>$accno_paid_bank--(.*?)<\/option>//;
627
      }
625 628
    }
626 629
    $form->{"selectAP_paid_$i"} = $form->{selectAP_paid};
627 630
    if (!$form->{"AP_paid_$i"}) {
bin/mozilla/is.pl
793 793
      $form->{"changeable_$i"} = 0;
794 794
    }
795 795
    # don't add manual bookings for charts which are assigned to real bank accounts
796
    # and are flagged for use with bank import
796 797
    my $bank_accounts = SL::DB::Manager::BankAccount->get_all();
797 798
    foreach my $bank (@{ $bank_accounts }) {
798
      my $accno_paid_bank = $bank->chart->accno;
799
      $form->{selectAR_paid} =~ s/<option>$accno_paid_bank--(.*?)<\/option>//;
799
      if ($bank->use_with_bank_import) {
800
        my $accno_paid_bank = $bank->chart->accno;
801
        $form->{selectAR_paid} =~ s/<option>$accno_paid_bank--(.*?)<\/option>//;
802
      }
800 803
    }
801 804

  
802 805
    $form->{"selectAR_paid_$i"} = $form->{selectAR_paid};
doc/changelog
11 11

  
12 12
Kleinere neue Features und Detailverbesserungen:
13 13

  
14
  - Bei den Bankkonten Auswahlmöglichkeit hinzugefügt, ob das Konto für den Bankimport
15
    verwendet (und somit für manuelle buchungen gesperrt) werden soll
16
    (Standardwert und bestehende: Ja)
14 17
  - Mahnsperre beim Kunden
15 18
  - Bei Mahnungen den schon erstellten Beleg mitversenden (Optional einstellbar in der
16 19
    Mahnunskonfiguration.
templates/design40_webpages/simple_system_setting/_bank_account_form.html
43 43
      <td>[% P.chart.picker("object.chart_id", SELF.object.chart_id, type='AR_paid,AP_paid', category='A,L,Q', choose=1, class='wi-wider', "data-validate"="required", "data-title"=LxERP.t8("Chart")) %]</td>
44 44
    </tr>
45 45
    <tr>
46
      <th></th>
47
      <td>[% LxERP.t8('This chart cannot be booked manually after assigning it to a real bank account.') %]</td>
46
      <th>[% LxERP.t8('Use with bank import') %]</th>
47
      <td>
48
        [% L.checkbox_tag('object.use_with_bank_import', checked = SELF.object.use_with_bank_import, for_submit=1) %]
49
        <br>
50
        <strong>[% LxERP.t8('Warning') %]:</strong> [% LxERP.t8('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.') %]
51
      </td>
48 52
    </tr>
49 53
    <tr>
50 54
     <th>[% LxERP.t8('Use for Factur-X/ZUGFeRD') %]</th>
templates/webpages/simple_system_setting/_bank_account_form.html
36 36
  <td>[% P.chart.picker('object.chart_id', SELF.object.chart_id, type='AR_paid,AP_paid', category='A,L,Q', choose=1, style=style, "data-validate"="required", "data-title"=LxERP.t8("Chart")) %]</td>
37 37
 </tr>
38 38
 <tr>
39
  <th align="right">[% LxERP.t8('Note') %]</th><td>[% LxERP.t8('This chart cannot be booked manually after assigning it to a real bank account.') %]</td>
40
 </tr>
39
  <th align="right">[% LxERP.t8('Use with bank import') %]</th>
40
  <td>
41
    [% L.checkbox_tag('object.use_with_bank_import', checked = SELF.object.use_with_bank_import, for_submit=1) %]
42
    <strong>[% LxERP.t8('Warning') %]:</strong> [% LxERP.t8('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.') %]
43
  </td>
44
</tr>
41 45
 <tr>
42 46
  <th align="right">[% LxERP.t8('Use for Factur-X/ZUGFeRD') %]</th>
43 47
  <td>[% L.checkbox_tag('object.use_for_zugferd', checked = SELF.object.use_for_zugferd, for_submit=1) %]</td>

Auch abrufbar als: Unified diff