From: Bernd Bleßmann Date: Tue, 9 Mar 2021 15:55:19 +0000 (+0100) Subject: Einkaufsrechnungen: Vorgangsbezeichnung speichern und danach suchen können X-Git-Tag: kivitendo-mebil_0.1-0~9^2~452 X-Git-Url: http://wagnertech.de/git?a=commitdiff_plain;h=1e09187933c03ee698a28310b34be95177c437eb;p=kivitendo-erp.git Einkaufsrechnungen: Vorgangsbezeichnung speichern und danach suchen können --- diff --git a/SL/AP.pm b/SL/AP.pm index 956528317..e21eb13ea 100644 --- a/SL/AP.pm +++ b/SL/AP.pm @@ -450,6 +450,7 @@ sub ap_transactions { qq|SELECT a.id, a.invnumber, a.transdate, a.duedate, a.amount, a.paid, | . qq| a.ordnumber, v.name, a.invoice, a.netamount, a.datepaid, a.notes, | . qq| a.globalproject_id, a.storno, a.storno_id, a.direct_debit, | . + qq| a.transaction_description, | . qq| pr.projectnumber AS globalprojectnumber, | . qq| e.name AS employee, | . qq| v.vendornumber, v.country, v.ustid, | . @@ -533,6 +534,10 @@ sub ap_transactions { $where .= " AND a.ordnumber ILIKE ?"; push(@values, like($form->{ordnumber})); } + if ($form->{transaction_description}) { + $where .= " AND a.transaction_description ILIKE ?"; + push(@values, like($form->{transaction_description})); + } if ($form->{notes}) { $where .= " AND lower(a.notes) LIKE ?"; push(@values, like($form->{notes})); diff --git a/SL/IR.pm b/SL/IR.pm index 2663ad676..3d8ee3637 100644 --- a/SL/IR.pm +++ b/SL/IR.pm @@ -737,7 +737,7 @@ SQL invoice = ?, taxzone_id = ?, notes = ?, taxincluded = ?, intnotes = ?, storno_id = ?, storno = ?, tax_point = ?, cp_id = ?, employee_id = ?, department_id = ?, delivery_term_id = ?, - payment_id = ?, + payment_id = ?, transaction_description = ?, currency_id = (SELECT id FROM currencies WHERE name = ?), globalproject_id = ?, direct_debit = ? WHERE id = ?|; @@ -748,7 +748,7 @@ SQL '1', $taxzone_id, $restricter->process($form->{notes}), $form->{taxincluded} ? 't' : 'f', $form->{intnotes}, conv_i($form->{storno_id}), $form->{storno} ? 't' : 'f', conv_date($form->{tax_point}), conv_i($form->{cp_id}), conv_i($form->{employee_id}), conv_i($form->{department_id}), conv_i($form->{delivery_term_id}), - conv_i($form->{payment_id}), + conv_i($form->{payment_id}), $form->{transaction_description}, $form->{"currency"}, conv_i($form->{globalproject_id}), $form->{direct_debit} ? 't' : 'f', @@ -1006,7 +1006,7 @@ sub retrieve_invoice { ordnumber, quonumber, paid, taxincluded, notes, taxzone_id, storno, gldate, mtime, itime, intnotes, (SELECT cu.name FROM currencies cu WHERE cu.id=ap.currency_id) AS currency, direct_debit, - payment_id, delivery_term_id + payment_id, delivery_term_id, transaction_description FROM ap WHERE id = ?|; $ref = selectfirst_hashref_query($form, $dbh, $query, conv_i($form->{id})); diff --git a/templates/webpages/ap/search.html b/templates/webpages/ap/search.html index 32ad40eea..94d34684d 100644 --- a/templates/webpages/ap/search.html +++ b/templates/webpages/ap/search.html @@ -29,6 +29,9 @@ [% 'Order Number' | $T8 %] [% L.input_tag("ordnumber", "", style=style) %] + + [% 'Transaction description' | $T8 %] + [% L.input_tag("transaction_description", "", style=style) %] [% 'Notes' | $T8 %] [% L.input_tag("notes", "", style=style) %] @@ -119,6 +122,8 @@ [% 'Subtotal' | $T8 %] [% 'Document Project Number' | $T8 %] + + [% 'Transaction description' | $T8 %] diff --git a/templates/webpages/ir/form_header.html b/templates/webpages/ir/form_header.html index fac160a03..296c79bcd 100644 --- a/templates/webpages/ir/form_header.html +++ b/templates/webpages/ir/form_header.html @@ -131,6 +131,10 @@ [%- END %] + + [% 'Transaction description' | $T8 %] + [% L.input_tag("transaction_description", transaction_description, size=35, "data-validate"=INSTANCE_CONF.get_require_transaction_description_ps ? 'required' : '') %] +