src/Entity/Gericht.php line 9

Open in your IDE?
  1. <?php
  2. namespace App\Entity;
  3. use App\Repository\GerichtRepository;
  4. use Doctrine\ORM\Mapping as ORM;
  5. #[ORM\Entity(repositoryClassGerichtRepository::class)]
  6. class Gericht
  7. {
  8.     #[ORM\Id]
  9.     #[ORM\GeneratedValue]
  10.     #[ORM\Column]
  11.     private ?int $id null;
  12.     #[ORM\Column(length255)]
  13.     private ?string $name null;
  14.     
  15.     #[ORM\Column(length255)]
  16.     private ?string $bild null;
  17.     
  18.     #[ORM\ManyToOne(targetEntity:'App\Entity\Kategorie'inversedBy:'gericht')]
  19.     private $kategorie null;
  20.     #[ORM\Column(length255nullabletrue)]
  21.     private ?string $beschreibung null;
  22.     #[ORM\Column(nullabletrue)]
  23.     private ?float $preis null;
  24.     public function getId(): ?int
  25.     {
  26.         return $this->id;
  27.     }
  28.     public function getName(): ?string
  29.     {
  30.         return $this->name;
  31.     }
  32.     public function setName(string $name): static
  33.     {
  34.         $this->name $name;
  35.         return $this;
  36.     }
  37.     public function getBeschreibung(): ?string
  38.     {
  39.         return $this->beschreibung;
  40.     }
  41.     public function setBeschreibung(?string $beschreibung): static
  42.     {
  43.         $this->beschreibung $beschreibung;
  44.         return $this;
  45.     }
  46.     public function getPreis(): ?float
  47.     {
  48.         return $this->preis;
  49.     }
  50.     public function setPreis(?float $preis): static
  51.     {
  52.         $this->preis $preis;
  53.         return $this;
  54.     }
  55.     public function getBild(): ?string
  56.     {
  57.         return $this->bild;
  58.     }
  59.     public function setBild(string $bild): static
  60.     {
  61.         $this->bild $bild;
  62.         return $this;
  63.     }
  64.     public function getKategorie(): ?Kategorie
  65.     {
  66.         return $this->kategorie;
  67.     }
  68.     public function setKategorie(?Kategorie $kategorie): static
  69.     {
  70.         $this->kategorie $kategorie;
  71.         return $this;
  72.     }
  73. }