From 18db0f54198bec7f6c1c318c71898190c6b268af Mon Sep 17 00:00:00 2001 From: Thomas Kasulke Date: Wed, 25 Apr 2007 11:49:04 +0000 Subject: [PATCH] =?utf8?q?history=20f=C3=BCr=20stornierte=20Buchungne=20ei?= =?utf8?q?ngef=C3=BCgt=20und=20rowcount=20hochgesetzt,=20damit=20die=20Sto?= =?utf8?q?rnierung=20in=20post()=20funktioniert?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- bin/mozilla/ir.pl | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/bin/mozilla/ir.pl b/bin/mozilla/ir.pl index ef30cea12..333549367 100644 --- a/bin/mozilla/ir.pl +++ b/bin/mozilla/ir.pl @@ -969,7 +969,7 @@ sub update { sub storno { $lxdebug->enter_sub(); - +use CGI::Carp qw(fatalsToBrowser); if ($form->{storno}) { $form->error($locale->text('Cannot storno storno invoice!')); } @@ -981,12 +981,20 @@ sub storno { invoice_links(); prepare_invoice(); relink_accounts(); - + + # saving the history + if(!exists $form->{addition} && $form->{id} ne "") { + $form->{snumbers} = qq|invnumber_| . $form->{invnumber}; + $form->{addition} = "CANCELED"; + $form->save_history($form->dbconnect(\%myconfig)); + } + # /saving the history + $form->{storno_id} = $form->{id}; $form->{storno} = 1; $form->{id} = ""; $form->{invnumber} = "Storno zu " . $form->{invnumber}; - + $form->{rowcount}++; &post(); $lxdebug->leave_sub(); -- 2.20.1