public function HomeboxLayout::setOwner in Homebox 8
Sets the entity owner's user entity.
Parameters
\Drupal\user\UserInterface $account: The owner user entity.
Return value
$this
Overrides EntityOwnerInterface::setOwner
File
- src/
Entity/ HomeboxLayout.php, line 179
Class
- HomeboxLayout
- Defines the Homebox Layout entity.
Namespace
Drupal\homebox\EntityCode
public function setOwner(UserInterface $account) {
$this
->set('user_id', $account
->id());
return $this;
}