resq/src/Entity/OwnershipType.php
2022-08-15 07:10:15 +00:00

63 lines
1 KiB
PHP

<?php
namespace App\Entity;
use Doctrine\ORM\Mapping as ORM;
use Symfony\Component\Validator\Constraints as Assert;
/**
* @ORM\Entity
* @ORM\Table(name="ownership_type", indexes={
* @ORM\Index(name="ownership_type_idx", columns={"code"}),
* })
*/
class OwnershipType
{
// unique id
/**
* @ORM\Id
* @ORM\Column(type="integer")
* @ORM\GeneratedValue(strategy="AUTO")
*/
protected $id;
/**
* @ORM\Column(type="string", length=25)
* @Assert\NotBlank()
*/
protected $code;
/**
* @ORM\Column(type="string", length=25)
* @Assert\NotBlank()
*/
protected $name;
public function getID()
{
return $this->id;
}
public function setName($name)
{
$this->name = $name;
return $this;
}
public function getName()
{
return $this->name;
}
public function setCode($code)
{
$this->code = $code;
return $this;
}
public function getCode()
{
return $this->code;
}
}