X-Git-Url: http://wagnertech.de/gitweb/gitweb.cgi/mfinanz.git/blobdiff_plain/5f6d6d4eaca3a3d238c678ef3f2a1fe676c3a77a..b6213d3539ccd179cd1f21b9afc54b8de8970774:/SL/IR.pm diff --git a/SL/IR.pm b/SL/IR.pm index 301fe3b64..931df6b44 100644 --- a/SL/IR.pm +++ b/SL/IR.pm @@ -720,9 +720,10 @@ sub post_invoice { } - # add shipto $form->{name} = $form->{vendor}; $form->{name} =~ s/--\Q$form->{vendor_id}\E//; + + # add shipto $form->add_shipto($dbh, $form->{id}, "AP"); # delete zero entries @@ -1126,16 +1127,6 @@ sub get_vendor { } $sth->finish(); - # get shipto if we do not convert an order or invoice - if (!$params->{shipto}) { - delete @{$params}{qw(shiptoname shiptostreet shiptozipcode shiptocity shiptocountry shiptocontact shiptophone shiptofax shiptoemail)}; - - $query = qq|SELECT * FROM shipto WHERE (trans_id = ?) AND (module= 'CT')|; - $ref = selectfirst_hashref_query($form, $dbh, $query, $vid); - @{$params}{keys %$ref} = @{$ref}{keys %$ref}; - map { $params->{$_} = $ref->{$_} } keys %$ref; - } - if (!$params->{id} && $params->{type} !~ /_(order|quotation)/) { # setup last accounts used $query =