accompanyingPeriod: add job

This commit is contained in:
nobohan
2022-01-19 10:17:22 +01:00
parent 2ff34688bb
commit 3471bdec0d
2 changed files with 62 additions and 0 deletions

View File

@@ -20,6 +20,7 @@ use Chill\MainBundle\Entity\HasScopesInterface;
use Chill\MainBundle\Entity\Location;
use Chill\MainBundle\Entity\Scope;
use Chill\MainBundle\Entity\User;
use Chill\MainBundle\Entity\UserJob;
use Chill\PersonBundle\Entity\AccompanyingPeriod\AccompanyingPeriodWork;
use Chill\PersonBundle\Entity\AccompanyingPeriod\ClosingMotive;
use Chill\PersonBundle\Entity\AccompanyingPeriod\Comment;
@@ -112,6 +113,15 @@ class AccompanyingPeriod implements
*/
public const STEP_DRAFT = 'DRAFT';
/**
* @ORM\ManyToOne(
* targetEntity=UserJob::class
* )
* @Groups({"read", "write"})
*/
private ?UserJob $job = null;
/**
* @ORM\ManyToOne(
* targetEntity=Address::class
@@ -394,6 +404,18 @@ class AccompanyingPeriod implements
return $array;
}
public function getJob(): ?UserJob
{
return $this->job;
}
public function setJob(?UserJob $job): self
{
$this->job = $job;
return $this;
}
public function addComment(Comment $comment): self
{
$this->comments[] = $comment;