Commit 995e720d authored by Laurent Lécluse's avatar Laurent Lécluse
Browse files

#34592

parent 55c7234d
......@@ -740,6 +740,14 @@ class ServiceService extends AbstractEntityService
public function setRealisesFromPrevus(Service $service)
{
$role = $this->getServiceContext()->getSelectedIdentityRole();
$rStructure = $role ? $role->getStructure() : null;
$sStructure = $service->getElementPedagogique() ? $service->getElementPedagogique()->getStructure() : null;
if ($rStructure && $sStructure && $rStructure != $sStructure) {
return; // on ne reporte pas de service si l'utilisateur est d'une composante différente de celle du service
}
$prevus = $service
->getVolumeHoraireListe()->createChild()
->setTypeVolumeHoraire($this->getServiceTypeVolumeHoraire()->getPrevu())
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment