From 85a6e1a3857c43bffeec46e08a2bda9c16419b03 Mon Sep 17 00:00:00 2001 From: "Martin Helmling martin.helmling@octosoft.eu" Date: Wed, 6 Jul 2016 19:32:33 +0200 Subject: [PATCH] =?utf8?q?Bei=20Einkaufsrechnungen=20und=20Debitorenbuchun?= =?utf8?q?gen=20neue=20W=C3=A4hrung=20abspeichern?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Währungs-Id wurde bisher beim Speichern nicht erneuert. --- SL/AR.pm | 5 ++++- SL/IR.pm | 2 ++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/SL/AR.pm b/SL/AR.pm index 82f89dfc2..d64ddb219 100644 --- a/SL/AR.pm +++ b/SL/AR.pm @@ -130,12 +130,15 @@ sub post_transaction { qq|UPDATE ar set invnumber = ?, ordnumber = ?, transdate = ?, customer_id = ?, taxincluded = ?, amount = ?, duedate = ?, paid = ?, + currency_id = (SELECT id FROM currencies WHERE name = ?), netamount = ?, notes = ?, department_id = ?, employee_id = ?, storno = ?, storno_id = ?, globalproject_id = ?, direct_debit = ? WHERE id = ?|; my @values = ($form->{invnumber}, $form->{ordnumber}, conv_date($form->{transdate}), conv_i($form->{customer_id}), $form->{taxincluded} ? 't' : 'f', $form->{amount}, - conv_date($form->{duedate}), $form->{paid}, $form->{netamount}, $form->{notes}, conv_i($form->{department_id}), + conv_date($form->{duedate}), $form->{paid}, + $form->{currency}, + $form->{netamount}, $form->{notes}, conv_i($form->{department_id}), conv_i($form->{employee_id}), $form->{storno} ? 't' : 'f', $form->{storno_id}, conv_i($form->{globalproject_id}), $form->{direct_debit} ? 't' : 'f', conv_i($form->{id})); do_query($form, $dbh, $query, @values); diff --git a/SL/IR.pm b/SL/IR.pm index 90dbbab96..5985f66b7 100644 --- a/SL/IR.pm +++ b/SL/IR.pm @@ -716,6 +716,7 @@ SQL invoice = ?, taxzone_id = ?, notes = ?, taxincluded = ?, intnotes = ?, storno_id = ?, storno = ?, cp_id = ?, employee_id = ?, department_id = ?, delivery_term_id = ?, + currency_id = (SELECT id FROM currencies WHERE name = ?), globalproject_id = ?, direct_debit = ? WHERE id = ?|; @values = ( @@ -725,6 +726,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_i($form->{cp_id}), conv_i($form->{employee_id}), conv_i($form->{department_id}), conv_i($form->{delivery_term_id}), + $form->{"currency"}, conv_i($form->{globalproject_id}), $form->{direct_debit} ? 't' : 'f', conv_i($form->{id}) -- 2.20.1