From bead93d9bf4fefcecb262c0af667b43b77f5dc9c Mon Sep 17 00:00:00 2001 From: =?utf8?q?Bernd=20Ble=C3=9Fmann?= Date: Mon, 23 Sep 2019 13:53:57 +0200 Subject: [PATCH] =?utf8?q?Bericht=20Angebote/Auftr=C3=A4ge:=20Abteilungen?= =?utf8?q?=20anzeigen=20k=C3=B6nnen?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- SL/OE.pm | 3 +++ bin/mozilla/oe.pl | 5 +++-- templates/webpages/oe/search.html | 4 ++++ 3 files changed, 10 insertions(+), 2 deletions(-) diff --git a/SL/OE.pm b/SL/OE.pm index 40b29f4a1..49681bd8e 100644 --- a/SL/OE.pm +++ b/SL/OE.pm @@ -116,6 +116,7 @@ sub transactions { qq| o.transaction_description, | . qq| o.marge_total, o.marge_percent, | . qq| o.itime::DATE AS insertdate, | . + qq| department.description as department, | . qq| ex.$rate AS exchangerate, | . qq| pt.description AS payment_terms, | . qq| pr.projectnumber AS globalprojectnumber, | . @@ -134,6 +135,7 @@ sub transactions { qq|LEFT JOIN project pr ON (o.globalproject_id = pr.id) | . qq|LEFT JOIN payment_terms pt ON (pt.id = o.payment_id)| . qq|LEFT JOIN tax_zones tz ON (o.taxzone_id = tz.id) | . + qq|LEFT JOIN department ON (o.department_id = department.id) | . qq|$periodic_invoices_joins | . qq|WHERE (o.quotation = ?) |; push(@values, $quotation); @@ -353,6 +355,7 @@ SQL "insertdate" => "o.itime", "taxzone" => "tz.description", "payment_terms" => "pt.description", + "department" => "department.description", ); if ($form->{sort} && grep($form->{sort}, keys(%allowed_sort_columns))) { $sortorder = $allowed_sort_columns{$form->{sort}} . " ${sortdir}" . ", o.itime ${sortdir}"; diff --git a/bin/mozilla/oe.pl b/bin/mozilla/oe.pl index c62e694a3..8c88f5337 100644 --- a/bin/mozilla/oe.pl +++ b/bin/mozilla/oe.pl @@ -1026,7 +1026,7 @@ sub orders { "curr", "employee", "salesman", "shipvia", "globalprojectnumber", - "transaction_description", "open", + "transaction_description", "department", "open", "delivered", "periodic_invoices", "marge_total", "marge_percent", "vcnumber", "ustid", @@ -1111,6 +1111,7 @@ sub orders { 'shipvia' => { 'text' => $locale->text('Ship via'), }, 'globalprojectnumber' => { 'text' => $locale->text('Project Number'), }, 'transaction_description' => { 'text' => $locale->text('Transaction description'), }, + 'department' => { 'text' => $locale->text('Department'), }, 'open' => { 'text' => $locale->text('Open'), }, 'delivered' => { 'text' => $locale->text('Delivery Order created'), }, 'marge_total' => { 'text' => $locale->text('Ertrag'), }, @@ -1129,7 +1130,7 @@ sub orders { %column_defs_cvars, ); - foreach my $name (qw(id transdate reqdate quonumber ordnumber cusordnumber name employee salesman shipvia transaction_description shippingpoint taxzone insertdate payment_terms)) { + foreach my $name (qw(id transdate reqdate quonumber ordnumber cusordnumber name employee salesman shipvia transaction_description shippingpoint taxzone insertdate payment_terms department)) { my $sortdir = $form->{sort} eq $name ? 1 - $form->{sortdir} : $form->{sortdir}; $column_defs{$name}->{link} = $href . "&sort=$name&sortdir=$sortdir"; } diff --git a/templates/webpages/oe/search.html b/templates/webpages/oe/search.html index 9362920b2..45a6f0aa0 100644 --- a/templates/webpages/oe/search.html +++ b/templates/webpages/oe/search.html @@ -257,6 +257,10 @@ + + [%- L.checkbox_tag('l_department', label => LxERP.t8('Department')) %] + + -- 2.20.1