Projekt

Allgemein

Profil

« Zurück | Weiter » 

Revision b3259be1

Von Jan Büren vor fast 6 Jahren hinzugefügt

  • ID b3259be1755d03539dfa8312f379bd0190526f25
  • Vorgänger eb087bc8
  • Nachfolger 800e16d8

Manuelle Zahlungen verbieten, falls mit Kontoauszug verknüpft.

Falls die Änderbarkeit von Zahlungen nicht auf niemals steht,
entsprechend Überbuchen / manuelles Ändern verbieten.
Der Fehlertext weißt zusätzlich auf die Funktion im Bankbewegungs-Bericht hin

Unterschiede anzeigen:

bin/mozilla/ar.pl
41 41
use SL::FU;
42 42
use SL::GL;
43 43
use SL::IS;
44
use SL::DB::BankTransactionAccTrans;
44 45
use SL::DB::Business;
45 46
use SL::DB::Chart;
46 47
use SL::DB::Currency;
......
1276 1277
  my $has_storno              = IS->has_storno(\%::myconfig, $::form, 'ar');
1277 1278
  my $may_edit_create         = $::auth->assert('ar_transactions', 1);
1278 1279

  
1280
  my $is_linked_bank_transaction;
1281
  if ($::form->{id}
1282
      && SL::DB::Default->get->payments_changeable != 0
1283
      && SL::DB::Manager::BankTransactionAccTrans->find_by(ar_id => $::form->{id})) {
1284

  
1285
    $is_linked_bank_transaction = 1;
1286
  }
1279 1287
  for my $bar ($::request->layout->get('actionbar')) {
1280 1288
    $bar->add(
1281 1289
      action => [
......
1297 1305
                    : $is_storno                                  ? t8('A canceled invoice cannot be posted.')
1298 1306
                    : ($::form->{id} && $change_never)            ? t8('Changing invoices has been disabled in the configuration.')
1299 1307
                    : ($::form->{id} && $change_on_same_day_only) ? t8('Invoices can only be changed on the day they are posted.')
1308
                    : $is_linked_bank_transaction                 ? t8('This transaction is linked with a bank transaction. Please undo and redo the bank transaction booking if needed.')
1300 1309
                    :                                               undef,
1301 1310
        ],
1302 1311
        action => [
1303 1312
          t8('Post Payment'),
1304 1313
          submit   => [ '#form', { action => "post_payment" } ],
1305
          disabled => !$may_edit_create ? t8('You must not change this AR transaction.')
1306
                    : !$::form->{id}    ? t8('This invoice has not been posted yet.')
1307
                    :                     undef,
1314
          disabled => !$may_edit_create           ? t8('You must not change this AR transaction.')
1315
                    : !$::form->{id}              ? t8('This invoice has not been posted yet.')
1316
                    : $is_linked_bank_transaction ? t8('This transaction is linked with a bank transaction. Please undo and redo the bank transaction booking if needed.')
1317
                    :                               undef,
1308 1318
        ],
1309 1319
        action => [ t8('Mark as paid'),
1310 1320
          submit   => [ '#form', { action => "mark_as_paid" } ],

Auch abrufbar als: Unified diff