src/Entity/Common/Passport.php line 16
<?php
namespace App\Entity\Common;
use Doctrine\ORM\Mapping as ORM;
use Symfony\Component\Validator\Constraints as Assert;
use App\Validator\Constraints\Common;
/**
* Class Passport
* @package App\Entity\Common
*
*/
#[ORM\Embeddable]
#[Common\Passport(groups:["russian_passport"])]
class Passport
{
#[ORM\Column(type: 'string', nullable: true)]
#[Assert\NotBlank(groups: ['russian_apply', 'russian_attendant'])]
private ?string $series = null;
#[ORM\Column(type: 'string', nullable: true)]
#[Assert\NotBlank(groups: ['full_apply_p', 'russian_attendant', 'foreign_attendant'])]
private ?string $number = null;
#[ORM\Column(type: 'text', nullable: true)]
#[Assert\NotBlank(groups: ['full_apply_p', 'russian_attendant', 'foreign_attendant'])]
private ?string $department_name = null;
#[ORM\Column(type: 'date', nullable: true)]
#[Assert\NotBlank(groups: ['full_apply_p', 'russian_attendant', 'foreign_attendant'])]
#[Assert\LessThanOrEqual('now', groups: ['Default', 'full_apply_p'])]
private ?\DateTime $issue_date = null;
#[ORM\Column(type: 'string', nullable: true)]
#[Assert\NotBlank(groups: ['russian_apply'])]
private ?string $department_code = null;
/**
* @return string|null
*/
public function getSeries(): ?string
{
return $this->series;
}
/**
* @param string|null $series
*/
public function setSeries(?string $series): void
{
$this->series = $series;
}
/**
* @return string|null
*/
public function getNumber(): ?string
{
return $this->number;
}
/**
* @param string|null $number
*/
public function setNumber(?string $number): void
{
$this->number = $number;
}
/**
* @return string|null
*/
public function getDepartmentName(): ?string
{
return $this->department_name;
}
/**
* @param string|null $department_name
*/
public function setDepartmentName(?string $department_name): void
{
$this->department_name = $department_name;
}
/**
* @return \DateTime|null
*/
public function getIssueDate(): ?\DateTime
{
return $this->issue_date;
}
/**
* @param \DateTime|null $issue_date
*/
public function setIssueDate(?\DateTime $issue_date): void
{
$this->issue_date = $issue_date;
}
/**
* @return string|null
*/
public function getDepartmentCode(): ?string
{
return $this->department_code;
}
/**
* @param string|null $department_code
*/
public function setDepartmentCode(?string $department_code): void
{
$this->department_code = $department_code;
}
}