SL::DB::Order: verwendete Klassen explizit requiren
[kivitendo-erp.git] / SL / DB / Order.pm
index a3c9de0..89f602e 100644 (file)
@@ -131,6 +131,7 @@ sub convert_to_invoice {
 
   my $invoice;
   if (!$self->db->do_transaction(sub {
+    require SL::DB::Invoice;
     $invoice = SL::DB::Invoice->new_from($self)->post(%params) || die;
     $self->link_to_record($invoice);
     $self->update_attributes(closed => 1);