]> wagnertech.de Git - kivitendo-erp.git/blobdiff - SL/OE.pm
GDPDU: statt acc_trans_id die trans_id exportieren
[kivitendo-erp.git] / SL / OE.pm
index 0e671bd38307ff2942149fea72bdfbca33adef50..86869f235221fe14782638b93453f81bdcb6e49c 100644 (file)
--- a/SL/OE.pm
+++ b/SL/OE.pm
@@ -885,8 +885,8 @@ sub _close_quotations_rfqs {
       $query = qq|UPDATE oe SET closed = TRUE WHERE id IN (| . join(', ', ('?') x scalar @close_ids) . qq|)|;
       do_query($form, $dbh, $query, @close_ids);
     }
-
-  });
+    1;
+  }) or do { die SL::DB->client->error };
 
   $main::lxdebug->leave_sub();
 }
@@ -905,7 +905,7 @@ sub delete {
     unlink map { "$spool/$_" } @spoolfiles if $spool;
 
     1;
-  });
+  }) or do { die SL::DB->client->error };
 
   $main::lxdebug->leave_sub();
 
@@ -1257,7 +1257,7 @@ sub order_details {
   my ($self, $myconfig, $form) = @_;
 
   # connect to database
-  my $dbh = $form->get_standard_dbh;
+  my $dbh = SL::DB->client->dbh;
   my $query;
   my @values = ();
   my $sth;
@@ -1605,8 +1605,6 @@ sub order_details {
 
   $form->{username} = $myconfig->{name};
 
-  $dbh->disconnect;
-
   $form->{delivery_term} = SL::DB::Manager::DeliveryTerm->find_by(id => $form->{delivery_term_id} || undef);
   $form->{delivery_term}->description_long($form->{delivery_term}->translated_attribute('description_long', $form->{language_id})) if $form->{delivery_term} && $form->{language_id};