Roomtypes headline according to hotel type
This commit is contained in:
@@ -875,4 +875,28 @@ class Hotel extends \TYPO3\CMS\Extbase\DomainObject\AbstractEntity implements Te
|
|||||||
$this->externalLink = $externalLink;
|
$this->externalLink = $externalLink;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @return bool
|
||||||
|
*/
|
||||||
|
public function getIsApartment()
|
||||||
|
{
|
||||||
|
return $this->getType() === self::TYPE_APPARTMENT;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @return bool
|
||||||
|
*/
|
||||||
|
public function getIsHolidayFlat()
|
||||||
|
{
|
||||||
|
return $this->getType() === self::TYPE_HOLIDAY_FLAT;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @return bool
|
||||||
|
*/
|
||||||
|
public function getIsOther()
|
||||||
|
{
|
||||||
|
return !$this->getIsApartment() && !$this->getIsHolidayFlat();
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -45,9 +45,23 @@
|
|||||||
<div class="hotel-details hotel-details--features">
|
<div class="hotel-details hotel-details--features">
|
||||||
{hotel.features -> f:format.html()}
|
{hotel.features -> f:format.html()}
|
||||||
</div>
|
</div>
|
||||||
<f:if condition="{bars}">
|
<f:if condition="{hotel.isApartment}">
|
||||||
<f:then><div class="ep-headbar">Zimmerarten / Apartments</div></f:then>
|
<f:if condition="{bars}">
|
||||||
<f:else><h2>Zimmerarten / Apartments</h2></f:else>
|
<f:then><div class="ep-headbar">Appartments</div></f:then>
|
||||||
|
<f:else><h2>Appartments</h2></f:else>
|
||||||
|
</f:if>
|
||||||
|
</f:if>
|
||||||
|
<f:if condition="{hotel.isHolidayFlat}">
|
||||||
|
<f:if condition="{bars}">
|
||||||
|
<f:then><div class="ep-headbar">Ferienwohnungen</div></f:then>
|
||||||
|
<f:else><h2>Ferienwohnungen</h2></f:else>
|
||||||
|
</f:if>
|
||||||
|
</f:if>
|
||||||
|
<f:if condition="{hotel.isOther}">
|
||||||
|
<f:if condition="{bars}">
|
||||||
|
<f:then><div class="ep-headbar">Zimmerarten</div></f:then>
|
||||||
|
<f:else><h2>Zimmerarten</h2></f:else>
|
||||||
|
</f:if>
|
||||||
</f:if>
|
</f:if>
|
||||||
<div class="hotel-details hotel-details--roomtypes">
|
<div class="hotel-details hotel-details--roomtypes">
|
||||||
{hotel.roomTypes -> f:format.html()}
|
{hotel.roomTypes -> f:format.html()}
|
||||||
|
|||||||
Reference in New Issue
Block a user