You are here

public function Event::setUnit in Booking and Availability Management Tools for Drupal 8

Overrides EventInterface::setUnit

File

modules/bat_event/src/Entity/Event.php, line 143
Contains \Drupal\bat_event\Entity\Event.

Class

Event
Defines the Event entity.

Namespace

Drupal\bat_event\Entity

Code

public function setUnit(UnitInterface $unit) {
  $this
    ->set('unit_id', $unit
    ->id());
  return $this;
}