hesabixCore/src/Entity/Business.php

37 lines
656 B
PHP
Raw Normal View History

2023-01-26 19:43:53 +03:30
<?php
namespace App\Entity;
use App\Repository\BusinessRepository;
use Doctrine\ORM\Mapping as ORM;
#[ORM\Entity(repositoryClass: BusinessRepository::class)]
class Business
{
#[ORM\Id]
#[ORM\GeneratedValue]
#[ORM\Column]
private ?int $id = null;
#[ORM\ManyToOne(inversedBy: 'businesses')]
#[ORM\JoinColumn(nullable: false)]
private ?User $owner = null;
public function getId(): ?int
{
return $this->id;
}
public function getOwner(): ?User
{
return $this->owner;
}
public function setOwner(?User $owner): self
{
$this->owner = $owner;
return $this;
}
}