feat: remove obsolete date range override
This commit is contained in:
1 parent
86c5d23181
commit
127ced4378
42 files changed
+152
-353
No files matched your search
@@ -21,9 +21,11 @@ class IcsGenerator
|
||||
$label = sprintf('E&P: Einteilung als %s', $assignment->getJobProfile()->getName());
|
||||
$address = sprintf("%s\n%s", $assignment->getDestination()->getProduct(), $assignment->getDestination()->getHotel());
|
||||
|
||||
$destination = $assignment->getDestination();
|
||||
|
||||
$event = Event::create($label)
|
||||
->startsAt($assignment->getEffectivePeriod()->start)
|
||||
->endsAt($assignment->getEffectivePeriod()->end->modify('+1 day'))
|
||||
->startsAt($destination->getDateFrom())
|
||||
->endsAt($destination->getDateTo()->modify('+1 day'))
|
||||
->address($address)
|
||||
->description($label)
|
||||
;
|
||||
|
||||
@@ -39,8 +39,8 @@ class ContractRenderer extends AbstractPdfRenderer
|
||||
$pdf->Text(21, 104.5, $pdf->encodeString($assignment->getJobProfile()->getName()));
|
||||
|
||||
// Period
|
||||
$dateFrom = $assignment->getEffectivePeriod()->start->format('d.m.Y');
|
||||
$dateTo = $assignment->getEffectivePeriod()->end->format('d.m.Y');
|
||||
$dateFrom = $destination->getDateFrom()->format('d.m.Y');
|
||||
$dateTo = $destination->getDateTo()->format('d.m.Y');
|
||||
$period = sprintf('%s - %s', $dateFrom, $dateTo);
|
||||
$pdf->Text(57, 113, $period);
|
||||
|
||||
|
||||
@@ -37,7 +37,7 @@ class InvoiceRenderer extends AbstractPdfRenderer
|
||||
|
||||
// Invoice number
|
||||
$pdf->SetFont('Arial', '', 12);
|
||||
$date = $assignment->getEffectivePeriod()->start->format('d/m/Y');
|
||||
$date = $assignment->getDestination()->getDateFrom()->format('d/m/Y');
|
||||
$suffix = $assignment->getId();
|
||||
$number = sprintf('%s-%05d', $date, $suffix);
|
||||
$pdf->Text(85, 116, $number);
|
||||
|
||||
Reference in new issue
Block a user