mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-06-12 21:34:25 +00:00
add container configuration for history tracking on person class
This commit is contained in:
parent
36fbcf9dae
commit
afb205cd99
@ -4,12 +4,12 @@ namespace CL\Chill\PersonBundle\Entity;
|
|||||||
|
|
||||||
use Doctrine\ORM\Mapping as ORM;
|
use Doctrine\ORM\Mapping as ORM;
|
||||||
use Symfony\Component\Validator\ExecutionContextInterface;
|
use Symfony\Component\Validator\ExecutionContextInterface;
|
||||||
|
use CL\CLHistoryBundle\Entity\IsHistoryContainer;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Person
|
* Person
|
||||||
*/
|
*/
|
||||||
class Person
|
class Person implements IsHistoryContainer {
|
||||||
{
|
|
||||||
/**
|
/**
|
||||||
* @var integer
|
* @var integer
|
||||||
*/
|
*/
|
||||||
@ -110,6 +110,16 @@ ou une valeur vide lorsque la donnée nest pas connue*/
|
|||||||
private $proxyHistoryOpenState = false;
|
private $proxyHistoryOpenState = false;
|
||||||
|
|
||||||
|
|
||||||
|
const HISTORY_DOMAIN = 'person';
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* @var string
|
||||||
|
*/
|
||||||
|
private $historyId = null;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
public function __construct(\DateTime $opening = null) {
|
public function __construct(\DateTime $opening = null) {
|
||||||
$this->history = new \Doctrine\Common\Collections\ArrayCollection();
|
$this->history = new \Doctrine\Common\Collections\ArrayCollection();
|
||||||
|
|
||||||
@ -714,8 +724,17 @@ ou une valeur vide lorsque la donnée nest pas connue*/
|
|||||||
return true;
|
return true;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public function getDomain() {
|
||||||
|
return self::HISTORY_DOMAIN;
|
||||||
|
}
|
||||||
|
|
||||||
|
public function getHistoryId() {
|
||||||
|
return $this->historyId;
|
||||||
|
}
|
||||||
|
|
||||||
|
public function setHistoryId($id) {
|
||||||
|
$this->historyId = $id;
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
@ -47,6 +47,9 @@ CL\Chill\PersonBundle\Entity\Person:
|
|||||||
proxyHistoryOpenState:
|
proxyHistoryOpenState:
|
||||||
type: boolean
|
type: boolean
|
||||||
name: proxy_open
|
name: proxy_open
|
||||||
|
historyId:
|
||||||
|
type: string
|
||||||
|
length: 40
|
||||||
manyToOne:
|
manyToOne:
|
||||||
countryOfBirth:
|
countryOfBirth:
|
||||||
targetEntity: CL\Chill\MainBundle\Entity\Country
|
targetEntity: CL\Chill\MainBundle\Entity\Country
|
||||||
|
Loading…
x
Reference in New Issue
Block a user