symfony-playground/src/Entity/MerParaDM.php

51 lines
1.0 KiB
PHP
Raw Normal View History

2022-05-23 13:22:36 +00:00
<?php
namespace App\Entity;
use App\Repository\MerParaDMRepository;
use Doctrine\ORM\Mapping as ORM;
#[ORM\Entity(repositoryClass: MerParaDMRepository::class)]
2022-05-25 07:54:28 +00:00
class MerParaDM extends MerService implements OttInterface
2022-05-23 13:22:36 +00:00
{
// #[ORM\Id]
// #[ORM\GeneratedValue]
// #[ORM\Column(type: 'integer')]
// private $id;
#[ORM\Column(type: 'string', length: 255)]
2022-05-24 08:06:04 +00:00
private $product_code;
2022-05-23 13:22:36 +00:00
2022-05-25 10:05:39 +00:00
#[ORM\OneToOne(targetEntity: MerDM::class, cascade: ['persist'])]
private MerDM $platform;
2022-05-23 13:22:36 +00:00
// public function getId(): ?int
// {
// return $this->id;
// }
public function getProductCode(): ?string
{
2022-05-24 08:06:04 +00:00
return $this->product_code;
2022-05-23 13:22:36 +00:00
}
public function setProductCode(string $productCode): self
{
2022-05-24 08:06:04 +00:00
$this->product_code = $productCode;
2022-05-23 13:22:36 +00:00
return $this;
}
2022-05-25 10:05:39 +00:00
public function getPlatform(): ?MerDM
{
return $this->platform;
}
public function setPlatform(?MerDM $platform): self
{
$this->platform = $platform;
return $this;
}
2022-05-23 13:22:36 +00:00
}