Beispiel #1
0
 public function migrateProperty($person, $propertyOrder, $label, $country = null, $territory = null, $location = null, $fromDate = null, $toDate = null, $provenDate = null, $comment = null)
 {
     //insert into new data
     $newProperty = new Property();
     $newProperty->setPerson($person);
     $newProperty->setPropertyOrder($propertyOrder);
     $newProperty->setLabel($this->normalize($label));
     $newProperty->setCountry($this->getCountry($country));
     $newProperty->setTerritory($this->getTerritory($territory, $location));
     $newProperty->setLocation($this->getLocation($location));
     $newProperty->setFromDate($this->getDate($fromDate));
     $newProperty->setToDate($this->getDate($toDate));
     $newProperty->setProvenDate($this->getDate($provenDate));
     $newProperty->setComment($this->normalize($comment));
     $this->getDBManager()->persist($newProperty);
     $this->getDBManager()->flush();
 }