diff --git a/trunk/app/Resources/views/default/components/booking/summary.html.twig b/trunk/app/Resources/views/default/components/booking/summary.html.twig
index 0647c852..87f6809e 100644
--- a/trunk/app/Resources/views/default/components/booking/summary.html.twig
+++ b/trunk/app/Resources/views/default/components/booking/summary.html.twig
@@ -27,7 +27,7 @@
{{ booking_price_info.final_payment|number_format(2) }} €
|
- Restzahlung (bis zum {{ booking_price_info.final_payment_date}}) |
+ Restzahlung ({{ booking_price_info.final_payment_date_str}}) |
diff --git a/trunk/src/AppBundle/Controller/BookingController.php b/trunk/src/AppBundle/Controller/BookingController.php
index 576cb9ec..ead210fd 100644
--- a/trunk/src/AppBundle/Controller/BookingController.php
+++ b/trunk/src/AppBundle/Controller/BookingController.php
@@ -227,6 +227,7 @@ class BookingController extends Controller
$outPriceInfo['departure_extra'] = 0;
$outPriceInfo['flight_price'] = 0;
$outPriceInfo['final_payment_date'] = $travelDate->getFinalPaymentDate();
+ $outPriceInfo['final_payment_date_str'] = $travelDate->getFinalPaymentDateStr();
}
if($bookingRequest->getDeparture() != null)
diff --git a/trunk/src/AppBundle/Entity/TravelDate.php b/trunk/src/AppBundle/Entity/TravelDate.php
index 3cc80eda..adeac521 100644
--- a/trunk/src/AppBundle/Entity/TravelDate.php
+++ b/trunk/src/AppBundle/Entity/TravelDate.php
@@ -165,11 +165,20 @@ final class TravelDate
{
$pDate = strtotime('-4 week', $this->getStart()->getTimestamp());
if($pDate <= time()){
- $pDate = strtotime('+1 day', $this->getStart()->getTimestamp());
+ $pDate = time();
}
return date('d.m.Y',$pDate);
}
+ public function getFinalPaymentDateStr()
+ {
+ $pDate = strtotime('-4 week', $this->getStart()->getTimestamp());
+ if($pDate <= time()){
+ return "ist sofort fällig";
+ }
+ return "bis zum ".date('d.m.Y',$pDate);
+ }
+
/**
* @return \DateTime