You are here

public function Unit::getUnitType in Booking and Availability Management Tools for Drupal 8

Returns the entity's UnitType entity.

Return value

\Drupal\bat_unit\UnitTypeInterface The UnitType entity.

Overrides UnitInterface::getUnitType

1 call to Unit::getUnitType()
Unit::getEventDefaultValue in modules/bat_unit/src/Entity/Unit.php

File

modules/bat_unit/src/Entity/Unit.php, line 117
Contains \Drupal\bat_unit\Entity\Unit.

Class

Unit
Defines the Unit entity.

Namespace

Drupal\bat_unit\Entity

Code

public function getUnitType() {
  return $this
    ->get('unit_type_id')->entity;
}