Loading module/Oscar/src/Oscar/Service/PersonDeleteService.php +6 −0 Original line number Diff line number Diff line Loading @@ -10,6 +10,7 @@ use Oscar\Entity\RecallDeclaration; use Oscar\Entity\RecallException; use Oscar\Entity\Referent; use Oscar\Entity\TimeSheet; use Oscar\Entity\WorkPackagePerson; use Oscar\Exception\OscarDeletePersonNotPossibleException; use Oscar\Exception\OscarException; use Oscar\Provider\Privileges; Loading Loading @@ -70,6 +71,11 @@ class PersonDeleteService implements UseOscarUserContextService, UseEntityManage ->setParameter('person', $person); $del->getQuery()->execute(); $del = $this->getEntityManager()->createQueryBuilder()->delete(WorkPackagePerson::class, 'n') ->where('n.person = :person') ->setParameter('person', $person); $del->getQuery()->execute(); $this->getEntityManager()->remove($person); $this->getEntityManager()->flush(); } Loading Loading
module/Oscar/src/Oscar/Service/PersonDeleteService.php +6 −0 Original line number Diff line number Diff line Loading @@ -10,6 +10,7 @@ use Oscar\Entity\RecallDeclaration; use Oscar\Entity\RecallException; use Oscar\Entity\Referent; use Oscar\Entity\TimeSheet; use Oscar\Entity\WorkPackagePerson; use Oscar\Exception\OscarDeletePersonNotPossibleException; use Oscar\Exception\OscarException; use Oscar\Provider\Privileges; Loading Loading @@ -70,6 +71,11 @@ class PersonDeleteService implements UseOscarUserContextService, UseEntityManage ->setParameter('person', $person); $del->getQuery()->execute(); $del = $this->getEntityManager()->createQueryBuilder()->delete(WorkPackagePerson::class, 'n') ->where('n.person = :person') ->setParameter('person', $person); $del->getQuery()->execute(); $this->getEntityManager()->remove($person); $this->getEntityManager()->flush(); } Loading