From: Sven Schöling Date: Wed, 12 Oct 2011 15:01:16 +0000 (+0200) Subject: Merge branch 'master' of vc.linet-services.de:public/lx-office-erp X-Git-Tag: release-2.7.0beta1~230 X-Git-Url: http://wagnertech.de/gitweb/gitweb.cgi/mfinanz.git/commitdiff_plain/1a106c11e3f0e22b84e92d6f52c232b5b47d3d99?ds=sidebyside;hp=-c Merge branch 'master' of vc.linet-services.de:public/lx-office-erp --- 1a106c11e3f0e22b84e92d6f52c232b5b47d3d99 diff --combined SL/IS.pm index bd385ef7d,d90a0d0db..c9a44281d --- a/SL/IS.pm +++ b/SL/IS.pm @@@ -353,9 -353,7 +353,9 @@@ sub invoice_details $sth->finish; } - map { push @{ $form->{TEMPLATE_ARRAYS}->{"ic_cvar_$_->{name}"} }, $form->{"ic_cvar_$_->{name}_$i"} } @{ $ic_cvar_configs }; + push @{ $form->{TEMPLATE_ARRAYS}->{"ic_cvar_$_->{name}"} }, + CVar->format_to_template(CVar->parse($form->{"ic_cvar_$_->{name}_$i"}, $_), $_) + for @{ $ic_cvar_configs }; } } @@@ -879,7 -877,7 +879,7 @@@ sub post_invoice # record payments and offsetting AR if (!$form->{storno}) { for my $i (1 .. $form->{paidaccounts}) { - + if ($form->{"acc_trans_id_$i"} && $payments_only && ($::lx_office_conf{features}->{payments_changeable} == 0)) { @@@ -1480,6 -1478,8 +1480,8 @@@ sub retrieve_invoice $ref = selectfirst_hashref_query($form, $dbh, $query, $id); map { $form->{$_} = $ref->{$_} } keys %{ $ref }; + # remove any trailing whitespace + $form->{currency} =~ s/\s*$//; $form->{exchangerate} = $form->get_exchangerate($dbh, $form->{currency}, $form->{invdate}, "buy"); diff --combined SL/OE.pm index cfe5e25b1,5bf2a3da9..bfa43f235 --- a/SL/OE.pm +++ b/SL/OE.pm @@@ -806,6 -806,9 +806,9 @@@ sub retrieve if ($ref) { map { $form->{$_} = $ref->{$_} } keys %$ref; + # remove any trailing whitespace + $form->{currency} =~ s/\s*$//; + $form->{saved_xyznumber} = $form->{$form->{type} =~ /_quotation$/ ? "quonumber" : "ordnumber"}; # set all entries for multiple ids blank that yield different information @@@ -1293,9 -1296,7 +1296,9 @@@ sub order_details $sth->finish; } - map { push @{ $form->{TEMPLATE_ARRAYS}->{"ic_cvar_$_->{name}"} }, $form->{"ic_cvar_$_->{name}_$i"} } @{ $ic_cvar_configs }; + push @{ $form->{TEMPLATE_ARRAYS}->{"ic_cvar_$_->{name}"} }, + CVar->format_to_template(CVar->parse($form->{"ic_cvar_$_->{name}_$i"}, $_), $_) + for @{ $ic_cvar_configs }; } }