From: Jan Büren Date: Thu, 12 Jul 2018 16:16:17 +0000 (+0200) Subject: Dialogbuchen, Betrag aus Kontoauszug verbuchen schreibschützen (Maske) X-Git-Tag: release-3.5.4~360 X-Git-Url: http://wagnertech.de/git?a=commitdiff_plain;h=2c33e93fb5caf10f96cfa462781830f28efa285c;p=kivitendo-erp.git Dialogbuchen, Betrag aus Kontoauszug verbuchen schreibschützen (Maske) Als Konsequenz aus dem vorherigen Commit, sollte der Benutzer erstmal nicht fröhlich Freitext-Werte in das Feld füllen. --- diff --git a/SL/Controller/BankTransaction.pm b/SL/Controller/BankTransaction.pm index 0420b8b36..7d7616787 100644 --- a/SL/Controller/BankTransaction.pm +++ b/SL/Controller/BankTransaction.pm @@ -890,6 +890,7 @@ sub load_gl_record_template_url { 'form_defaults.transdate' => $self->transaction->transdate_as_date, 'form_defaults.callback' => $self->callback, 'form_defaults.bt_id' => $self->transaction->id, + 'form_defaults.bt_chart_id' => $self->transaction->local_bank_account->chart->id, ); } diff --git a/bin/mozilla/gl.pl b/bin/mozilla/gl.pl index f351a9dfc..f816dcd56 100644 --- a/bin/mozilla/gl.pl +++ b/bin/mozilla/gl.pl @@ -917,6 +917,12 @@ sub display_rows { my $copy2credit = $i == 1 ? 'onkeyup="copy_debit_to_credit()"' : ''; my $balance = $form->format_amount(\%::myconfig, $balances{$accno_id} // 0, 2, 'DRCR'); + # if we have a bt_chart_id we disallow changing the amount of the bank account + if ($form->{bt_chart_id}) { + $debitreadonly = $creditreadonly = "readonly" if ($form->{"accno_id_$i"} eq $form->{bt_chart_id}); + $copy2credit = '' if $i == 1; # and disallow copy2credit + } + print qq| $accno ${balance} diff --git a/templates/webpages/gl/form_footer.html b/templates/webpages/gl/form_footer.html index 8e7d74dc5..b5769bd44 100644 --- a/templates/webpages/gl/form_footer.html +++ b/templates/webpages/gl/form_footer.html @@ -21,6 +21,7 @@
+ [%- IF id && follow_ups.size %]

[% LxERP.t8('There are #1 unfinished follow-ups of which #2 are due.', follow_ups.size , follow_ups_due) %]