correction
This commit is contained in:
parent
a095f6504b
commit
92ce9cbaaa
|
@ -138,12 +138,15 @@ class uploadListener
|
||||||
if($fgexit) $message="Modification fichier<br>".$filename;
|
if($fgexit) $message="Modification fichier<br>".$filename;
|
||||||
else $message="Création fichier<br>".$filename;
|
else $message="Création fichier<br>".$filename;
|
||||||
|
|
||||||
$key=$this->em->getRepository("CadolesCoreBundle:Usergroup")->findOneBy(["group"=>$group,"user"=>$this->token->getToken()->getUser()])->getKeyvalue();
|
$usergroup=$this->em->getRepository("CadolesCoreBundle:Usergroup")->findOneBy(["group"=>$group,"user"=>$this->token->getToken()->getUser()]);
|
||||||
|
if($usergroup) {
|
||||||
|
$key=$usergroup->getKeyvalue();
|
||||||
$websocket = $this->container->get('cadoles.websocket.pushmessage')->send($key,$this->token->getToken()->getUser()->getId(),$group->getId(),$message);
|
$websocket = $this->container->get('cadoles.websocket.pushmessage')->send($key,$this->token->getToken()->getUser()->getId(),$group->getId(),$message);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
$response = $event->getResponse();
|
$response = $event->getResponse();
|
||||||
$response['file'] = $filename;
|
$response['file'] = $filename;
|
||||||
|
|
|
@ -59,10 +59,13 @@ class BlogarticleController extends Controller
|
||||||
if($group->getFgcanshare()) {
|
if($group->getFgcanshare()) {
|
||||||
$url=$this->generateUrl('cadoles_portal_'.$access.'_blogarticle_view',["id"=>$entity->getId()]);
|
$url=$this->generateUrl('cadoles_portal_'.$access.'_blogarticle_view',["id"=>$entity->getId()]);
|
||||||
$message="Création article<br><a href='$url'>".$entity->getName()."</a>";
|
$message="Création article<br><a href='$url'>".$entity->getName()."</a>";
|
||||||
$key=$em->getRepository("CadolesCoreBundle:Usergroup")->findOneBy(["group"=>$group,"user"=>$this->getUser()])->getKeyvalue();
|
$usergroup=$em->getRepository("CadolesCoreBundle:Usergroup")->findOneBy(["group"=>$group,"user"=>$this->getUser()]);
|
||||||
|
if($usergroup) {
|
||||||
|
$key=$usergroup->getKeyvalue();
|
||||||
$websocket = $this->container->get('cadoles.websocket.pushmessage')->send($key,$this->getUser()->getId(),$group->getId(),$message);
|
$websocket = $this->container->get('cadoles.websocket.pushmessage')->send($key,$this->getUser()->getId(),$group->getId(),$message);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
return $this->redirect($this->generateUrl('cadoles_portal_'.$access.'_blogarticle_view',["id"=>$entity->getId()]));
|
return $this->redirect($this->generateUrl('cadoles_portal_'.$access.'_blogarticle_view',["id"=>$entity->getId()]));
|
||||||
}
|
}
|
||||||
|
@ -104,10 +107,13 @@ class BlogarticleController extends Controller
|
||||||
if($group->getFgcanshare()) {
|
if($group->getFgcanshare()) {
|
||||||
$url=$this->generateUrl('cadoles_portal_'.$access.'_blogarticle_view',["id"=>$entity->getId()]);
|
$url=$this->generateUrl('cadoles_portal_'.$access.'_blogarticle_view',["id"=>$entity->getId()]);
|
||||||
$message="Modification article<br><a href='$url'>".$entity->getName()."</a>";
|
$message="Modification article<br><a href='$url'>".$entity->getName()."</a>";
|
||||||
$key=$em->getRepository("CadolesCoreBundle:Usergroup")->findOneBy(["group"=>$group,"user"=>$this->getUser()])->getKeyvalue();
|
$usergroup=$em->getRepository("CadolesCoreBundle:Usergroup")->findOneBy(["group"=>$group,"user"=>$this->getUser()]);
|
||||||
|
if($usergroup) {
|
||||||
|
$key=$usergroup->getKeyvalue();
|
||||||
$websocket = $this->container->get('cadoles.websocket.pushmessage')->send($key,$this->getUser()->getId(),$group->getId(),$message);
|
$websocket = $this->container->get('cadoles.websocket.pushmessage')->send($key,$this->getUser()->getId(),$group->getId(),$message);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
return $this->redirect($this->generateUrl('cadoles_portal_'.$access.'_blogarticle_view',["id"=>$entity->getId()]));
|
return $this->redirect($this->generateUrl('cadoles_portal_'.$access.'_blogarticle_view',["id"=>$entity->getId()]));
|
||||||
}
|
}
|
||||||
|
|
|
@ -67,11 +67,14 @@ class BookmarkController extends Controller
|
||||||
foreach($pagewidget->getPage()->getGroups() as $groupchat) {
|
foreach($pagewidget->getPage()->getGroups() as $groupchat) {
|
||||||
if($groupchat->getFgcanshare()) {
|
if($groupchat->getFgcanshare()) {
|
||||||
$message="Création favoris<br><a href='".$data->getUrl()."' target='_blank'>".$data->getTitle()."</a>";
|
$message="Création favoris<br><a href='".$data->getUrl()."' target='_blank'>".$data->getTitle()."</a>";
|
||||||
$key=$em->getRepository("CadolesCoreBundle:Usergroup")->findOneBy(["group"=>$groupchat,"user"=>$this->getUser()])->getKeyvalue();
|
$usergroup=$em->getRepository("CadolesCoreBundle:Usergroup")->findOneBy(["group"=>$groupchat,"user"=>$this->getUser()]);
|
||||||
|
if($usergroup) {
|
||||||
|
$key=$usergroup->getKeyvalue();
|
||||||
$websocket = $this->container->get('cadoles.websocket.pushmessage')->send($key,$this->getUser()->getId(),$groupchat->getId(),$message);
|
$websocket = $this->container->get('cadoles.websocket.pushmessage')->send($key,$this->getUser()->getId(),$groupchat->getId(),$message);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// Retour à la page
|
// Retour à la page
|
||||||
return $this->redirect($this->generateUrl('cadoles_portal_'.$access.'_page_view',["id"=>$idpage,"usage"=>$usage,"group"=>$group]));
|
return $this->redirect($this->generateUrl('cadoles_portal_'.$access.'_page_view',["id"=>$idpage,"usage"=>$usage,"group"=>$group]));
|
||||||
|
@ -155,11 +158,14 @@ class BookmarkController extends Controller
|
||||||
foreach($pagewidget->getPage()->getGroups() as $groupchat) {
|
foreach($pagewidget->getPage()->getGroups() as $groupchat) {
|
||||||
if($groupchat->getFgcanshare()) {
|
if($groupchat->getFgcanshare()) {
|
||||||
$message="Modification favoris<br><a href='".$data->getUrl()."' target='_blank'>".$data->getTitle()."</a>";
|
$message="Modification favoris<br><a href='".$data->getUrl()."' target='_blank'>".$data->getTitle()."</a>";
|
||||||
$key=$em->getRepository("CadolesCoreBundle:Usergroup")->findOneBy(["group"=>$groupchat,"user"=>$this->getUser()])->getKeyvalue();
|
$usergroup=$em->getRepository("CadolesCoreBundle:Usergroup")->findOneBy(["group"=>$groupchat,"user"=>$this->getUser()]);
|
||||||
|
if($usergroup) {
|
||||||
|
$key=$usergroup->getKeyvalue();
|
||||||
$websocket = $this->container->get('cadoles.websocket.pushmessage')->send($key,$this->getUser()->getId(),$groupchat->getId(),$message);
|
$websocket = $this->container->get('cadoles.websocket.pushmessage')->send($key,$this->getUser()->getId(),$groupchat->getId(),$message);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// Retour à la page
|
// Retour à la page
|
||||||
return $this->redirect($this->generateUrl('cadoles_portal_'.$access.'_page_view',["id"=>$idpage,"usage"=>$usage,"group"=>$group]));
|
return $this->redirect($this->generateUrl('cadoles_portal_'.$access.'_page_view',["id"=>$idpage,"usage"=>$usage,"group"=>$group]));
|
||||||
|
|
|
@ -128,10 +128,13 @@ class CalendareventController extends Controller
|
||||||
foreach($calendarevent->getCalendar()->getGroups() as $group) {
|
foreach($calendarevent->getCalendar()->getGroups() as $group) {
|
||||||
if($group->getFgcanshare()) {
|
if($group->getFgcanshare()) {
|
||||||
$message="Création évènement<br>".$calendarevent->getName()."<br>du ".$start->format("d/m/Y H:i")." au ".$end->sub(new \DateInterval('PT1M'))->format("d/m/Y H:i");
|
$message="Création évènement<br>".$calendarevent->getName()."<br>du ".$start->format("d/m/Y H:i")." au ".$end->sub(new \DateInterval('PT1M'))->format("d/m/Y H:i");
|
||||||
$key=$em->getRepository("CadolesCoreBundle:Usergroup")->findOneBy(["group"=>$group,"user"=>$this->getUser()])->getKeyvalue();
|
$usergroup=$em->getRepository("CadolesCoreBundle:Usergroup")->findOneBy(["group"=>$group,"user"=>$this->getUser()]);
|
||||||
|
if($usergroup) {
|
||||||
|
$key=$usergroup->getKeyvalue();
|
||||||
$websocket = $this->container->get('cadoles.websocket.pushmessage')->send($key,$this->getUser()->getId(),$group->getId(),$message);
|
$websocket = $this->container->get('cadoles.websocket.pushmessage')->send($key,$this->getUser()->getId(),$group->getId(),$message);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
$output["id"]=$calendarevent->getId();
|
$output["id"]=$calendarevent->getId();
|
||||||
$output["color"]="#".(is_null($calendar->getColor())?$this->get('session')->get('color')["main"]:$calendar->getColor());
|
$output["color"]="#".(is_null($calendar->getColor())?$this->get('session')->get('color')["main"]:$calendar->getColor());
|
||||||
|
@ -181,10 +184,13 @@ class CalendareventController extends Controller
|
||||||
foreach($calendarevent->getCalendar()->getGroups() as $group) {
|
foreach($calendarevent->getCalendar()->getGroups() as $group) {
|
||||||
if($group->getFgcanshare()) {
|
if($group->getFgcanshare()) {
|
||||||
$message="Modification évènement<br>".$calendarevent->getName()."<br>du ".$start->format("d/m/Y H:i")." au ".$end->sub(new \DateInterval('PT1M'))->format("d/m/Y H:i");
|
$message="Modification évènement<br>".$calendarevent->getName()."<br>du ".$start->format("d/m/Y H:i")." au ".$end->sub(new \DateInterval('PT1M'))->format("d/m/Y H:i");
|
||||||
$key=$em->getRepository("CadolesCoreBundle:Usergroup")->findOneBy(["group"=>$group,"user"=>$this->getUser()])->getKeyvalue();
|
$usergroup=$em->getRepository("CadolesCoreBundle:Usergroup")->findOneBy(["group"=>$group,"user"=>$this->getUser()]);
|
||||||
|
if($usergroup) {
|
||||||
|
$key=$usergroup->getKeyvalue();
|
||||||
$websocket = $this->container->get('cadoles.websocket.pushmessage')->send($key,$this->getUser()->getId(),$group->getId(),$message);
|
$websocket = $this->container->get('cadoles.websocket.pushmessage')->send($key,$this->getUser()->getId(),$group->getId(),$message);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
$output["id"]=$calendarevent->getId();
|
$output["id"]=$calendarevent->getId();
|
||||||
$output["color"]="#".(is_null($calendar->getColor())?$this->get('session')->get('color')["main"]:$calendar->getColor());
|
$output["color"]="#".(is_null($calendar->getColor())?$this->get('session')->get('color')["main"]:$calendar->getColor());
|
||||||
|
|
Loading…
Reference in New Issue