person: add civility: entity, migration, form, twig, config

This commit is contained in:
nobohan
2021-11-08 11:41:45 +01:00
parent 1dbf29beea
commit fa05a6856a
9 changed files with 112 additions and 4 deletions

View File

@@ -34,6 +34,7 @@ use Chill\PersonBundle\Entity\MaritalStatus;
use Chill\PersonBundle\Entity\Household\HouseholdMember;
use Chill\MainBundle\Entity\HasCenterInterface;
use Chill\MainBundle\Entity\Address;
use Chill\MainBundle\Entity\Civility;
use Chill\MainBundle\Entity\Embeddable\CommentEmbeddable;
use Chill\PersonBundle\Entity\Person\PersonCurrentAddress;
use DateTime;
@@ -212,6 +213,15 @@ class Person implements HasCenterInterface, TrackCreationInterface, TrackUpdateI
*/
private $maritalStatus;
/**
* The marital status of the person
* @var Civility
*
* @ORM\ManyToOne(targetEntity="Chill\MainBundle\Entity\Civility")
* @ORM\JoinColumn(nullable=true)
*/
private $civility;
/**
* The date of the last marital status change of the person
* @var \DateTime
@@ -962,6 +972,28 @@ class Person implements HasCenterInterface, TrackCreationInterface, TrackUpdateI
return $this->maritalStatus;
}
/**
* Set civility
*
* @param Civility $civility
* @return Person
*/
public function setCivility(Civility $civility = null)
{
$this->civility = $civility;
return $this;
}
/**
* Get civility
*
* @return Civility
*/
public function getCivility()
{
return $this->civility;
}
/**
* Set contactInfo
*