X-Git-Url: http://wagnertech.de/git?a=blobdiff_plain;f=bin%2Fmozilla%2Foe.pl;h=d6783443f2fd7b13bb300851d1022b040db393a8;hb=62f99e30c191d86af9249b6ec61f410dbe46466d;hp=72093443d461219ce2ad7a5342b9d13794bff631;hpb=19be3a57dbffa4a66be9f1cffdf5fc2a18332567;p=kivitendo-erp.git
diff --git a/bin/mozilla/oe.pl b/bin/mozilla/oe.pl
index 72093443d..d6783443f 100644
--- a/bin/mozilla/oe.pl
+++ b/bin/mozilla/oe.pl
@@ -1618,7 +1618,9 @@ sub orders {
. qq||;
$column_header{quonumber} =
qq|
|
- . $locale->text('Quotation')
+ . ($form->{"type"} eq "request_quotation" ?
+ $locale->text('RFQ') :
+ $locale->text('Quotation'))
. qq| | |;
$column_header{name} =
qq|$name | |;
@@ -2141,6 +2143,13 @@ sub invoice {
$form->{cp_id} *= 1;
+ for $i (1 .. $form->{rowcount}) {
+ map({ $form->{"${_}_${i}"} = $form->parse_amount(\%myconfig,
+ $form->{"${_}_${i}"})
+ if ($form->{"${_}_${i}"}) }
+ qw(ship qty sellprice listprice basefactor));
+ }
+
if ( $form->{type} =~ /_order/
&& $form->{currency} ne $form->{defaultcurrency}) {
@@ -2165,8 +2174,7 @@ sub invoice {
# if not it's most likely a collective order, which can't be saved back
# so they just have to be closed
if (($form->{ordnumber} ne '') || ($form->{quonumber} ne '')) {
- relink_accounts();
- OE->save(\%myconfig, \%$form);
+ OE->close_order(\%myconfig, \%$form);
} else {
OE->close_orders(\%myconfig, \%$form);
}
@@ -2432,9 +2440,7 @@ sub purchase_order {
if ( $form->{type} eq 'sales_quotation'
|| $form->{type} eq 'request_quotation') {
- $form->{closed} = 1;
- relink_accounts();
- OE->save(\%myconfig, \%$form);
+ OE->close_order(\%myconfig, \%$form);
}
$form->{cp_id} *= 1;
@@ -2453,9 +2459,7 @@ sub sales_order {
if ( $form->{type} eq 'sales_quotation'
|| $form->{type} eq 'request_quotation') {
- $form->{closed} = 1;
- relink_accounts();
- OE->save(\%myconfig, \%$form);
+ OE->close_order(\%myconfig, $form);
}
$form->{cp_id} *= 1;