X-Git-Url: http://wagnertech.de/gitweb/gitweb.cgi/mfinanz.git/blobdiff_plain/1f2a5b4c5f9ed16e455971d139cf5a1a14212228..d1a7b626e6b6b87539643016a2227c632e64e62b:/SL/DB/DeliveryOrder.pm diff --git a/SL/DB/DeliveryOrder.pm b/SL/DB/DeliveryOrder.pm index 411132bc4..1e0cb49b5 100644 --- a/SL/DB/DeliveryOrder.pm +++ b/SL/DB/DeliveryOrder.pm @@ -227,11 +227,12 @@ sub new_from_time_recordings { } my $date = $source->start_time->to_kivitendo; - $entries->{$part_id}->{$date}->{duration} += $source->{rounding} ? - nhimult(0.25, ($source->duration_in_hours)) - : _round_total($source->duration_in_hours); + $entries->{$part_id}->{$date}->{duration} += $source->{rounding} + ? nhimult(0.25, ($source->duration_in_hours)) + : _round_total($source->duration_in_hours); # add content if not already in description - my $new_description = $source->description_as_stripped_html; + my $new_description = '' . $source->description_as_stripped_html; + $entries->{$part_id}->{$date}->{content} ||= ''; $entries->{$part_id}->{$date}->{content} .= '
  • ' . $new_description . '
  • ' unless $entries->{$part_id}->{$date}->{content} =~ m/\Q$new_description/; @@ -402,7 +403,7 @@ order. =item C -Creates a new C instace from the time recordings +Creates a new C instance from the time recordings given as C<$sources>. All time recording entries must belong to the same customer. Time recordings are sorted by article and date. For each article a new delivery order item is created. If no article is associated with an