Compare commits
No commits in common. "0138bb6036a938ea676d1e26ad23355d9dd705e7" and "bfa43476920f0bc3c3eeab277d0494ec93963e07" have entirely different histories.
0138bb6036
...
bfa4347692
4 changed files with 12 additions and 18 deletions
|
|
@ -177,7 +177,6 @@
|
|||
</thead>
|
||||
<tbody>
|
||||
{% for price in fewo_lodging.prices %}
|
||||
{% if price.season is not empty %}
|
||||
<tr>
|
||||
<td data-title="Name">
|
||||
<strong class="small">
|
||||
|
|
@ -205,7 +204,6 @@
|
|||
{% endif %}
|
||||
</td>
|
||||
</tr>
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
</table>
|
||||
|
|
|
|||
|
|
@ -531,7 +531,6 @@ class FewoLodging
|
|||
{
|
||||
|
||||
return $this->getPrices()->filter(function(FewoPrice $price) use ($dateFrom, $dateTo) {
|
||||
if(!empty($price->getSeason()))
|
||||
return ($price->getSeason()->getFromDate() >= $dateFrom && $price->getSeason()->getFromDate() <= $dateTo) ||
|
||||
($price->getSeason()->getToDate() >= $dateFrom && $price->getSeason()->getToDate() <= $dateTo);
|
||||
});
|
||||
|
|
@ -615,7 +614,7 @@ class FewoLodging
|
|||
public function getReservationsFilter($dateFrom, $dateTo)
|
||||
{
|
||||
return $this->getReservations()->filter(function(FewoReservation $reservation) use ($dateFrom, $dateTo) {
|
||||
return ($reservation->getFromDate() >= $dateFrom && $reservation->getFromDate() <= $dateTo) ||
|
||||
return ($reservation->getFromDate() >= $dateFrom && $reservation->getFromDate() <= $dateTo) ||
|
||||
($reservation->getToDate() >= $dateFrom && $reservation->getToDate() <= $dateTo);
|
||||
});
|
||||
}
|
||||
|
|
|
|||
|
|
@ -780,23 +780,20 @@ class LodgingCalendarService
|
|||
$checkDay = $paddedCalendar[$mSdt->format("Y-n")]['data'][$key];
|
||||
|
||||
|
||||
if(!empty($checkDay->getPrice()->getSeason()) && $minDays != $checkDay->getPrice()->getSeason()->getMinimumStay()){
|
||||
|
||||
if(!empty($checkDay->getPrice())){
|
||||
if(!empty($checkDay->getPrice()->getSeason()) && $minDays != $checkDay->getPrice()->getSeason()->getMinimumStay()){
|
||||
|
||||
if($minDays > $checkDay->getPrice()->getSeason()->getMinimumStay()){
|
||||
$last = $counter+$checkDay->getPrice()->getSeason()->getMinimumStay();
|
||||
if($minDays > $checkDay->getPrice()->getSeason()->getMinimumStay()){
|
||||
$last = $counter+$checkDay->getPrice()->getSeason()->getMinimumStay();
|
||||
|
||||
|
||||
$setMinStayTo->modify('-'.($last).' days');
|
||||
}
|
||||
if($minDays < $checkDay->getPrice()->getSeason()->getMinimumStay()){
|
||||
$last = $counter+$checkDay->getPrice()->getSeason()->getMinimumStay();
|
||||
$setMinStayTo->modify('-'.($last).' days');
|
||||
|
||||
}
|
||||
$minDays = $checkDay->getPrice()->getSeason()->getMinimumStay();
|
||||
$setMinStayTo->modify('-'.($last).' days');
|
||||
}
|
||||
if($minDays < $checkDay->getPrice()->getSeason()->getMinimumStay()){
|
||||
$last = $counter+$checkDay->getPrice()->getSeason()->getMinimumStay();
|
||||
$setMinStayTo->modify('-'.($last).' days');
|
||||
|
||||
}
|
||||
$minDays = $checkDay->getPrice()->getSeason()->getMinimumStay();
|
||||
}
|
||||
$counter++;
|
||||
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@ libxml_use_internal_errors(true);
|
|||
$loader = require __DIR__.'/../app/autoload.php';
|
||||
include_once __DIR__.'/../var/bootstrap.php.cache';
|
||||
|
||||
$kernel = new AppKernel('dev', true);
|
||||
$kernel = new AppKernel('prod', false);
|
||||
$kernel->loadClassCache();
|
||||
//$kernel = new AppCache($kernel);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue