From: Jan Büren Date: Fri, 8 Mar 2019 11:58:13 +0000 (+0100) Subject: Kreditorenbeleg: Kontenbeschreibung für Zahlungskonten anzeigen X-Git-Tag: release-3.5.4~102 X-Git-Url: http://wagnertech.de/git?a=commitdiff_plain;h=9e30e4f6930108207ecaa77a57f0baee243ebaa6;p=kivitendo-erp.git Kreditorenbeleg: Kontenbeschreibung für Zahlungskonten anzeigen Wie bei EK-Rechnung. Zur Sicherheit ein eigenes Form-Feld generiert, anstatt die select box nur zu disablen. --- diff --git a/bin/mozilla/ap.pl b/bin/mozilla/ap.pl index 039f5a963..559154854 100644 --- a/bin/mozilla/ap.pl +++ b/bin/mozilla/ap.pl @@ -44,6 +44,7 @@ use SL::IR; use SL::IS; use SL::ReportGenerator; use SL::DB::BankTransactionAccTrans; +use SL::DB::Chart; use SL::DB::Currency; use SL::DB::Default; use SL::DB::PurchaseInvoice; @@ -553,6 +554,10 @@ sub form_header { $form->{'paidaccount_changeable_'. $i} = $changeable; $form->{'labelpaid_project_id_'. $i} = $project_labels{$form->{'paid_project_id_'. $i}}; + # accno and description as info text + $form->{'AP_paid_readonly_desc_' . $i} = $form->{'AP_paid_' . $i} ? + $form->{'AP_paid_' . $i} . " " . SL::DB::Manager::Chart->find_by(accno => $form->{'AP_paid_' . $i})->description + : ''; } $form->{paid_missing} = $form->{invtotal_unformatted} - $form->{totalpaid}; diff --git a/templates/webpages/ap/form_header.html b/templates/webpages/ap/form_header.html index 45dcf332a..fd8c91e54 100644 --- a/templates/webpages/ap/form_header.html +++ b/templates/webpages/ap/form_header.html @@ -331,12 +331,13 @@ [% END %] - [% temp = "AP_paid_"_ i %] + [% temp = "AP_paid_"_ i %] + [% readonly = "AP_paid_readonly_desc_"_ i %] [% IF( changeable ) %] [% L.select_tag(temp, ALL_CHARTS_AP_paid, value_title_sub = \AP_paid_value_title_sub, default = ($temp || accno_arap)) %] [% ELSE %] - [% $temp | html %] + [% $readonly | html %] [% END %]