/**
  * Copy a GadgetProgressBar entity.
  *
  * @Route("/{id}/copy", name="gadgetprogressbar_copy")
  * @param GadgetProgressBar $gadgetProgressBar
  * @return RedirectResponse
  */
 public function copyAction(GadgetProgressBar $gadgetProgressBar)
 {
     $gadgetProgressBar->getPage()->getId();
     $gadgetProgressBar_new = clone $gadgetProgressBar;
     $em = $this->getDoctrine()->getManager();
     $em->persist($gadgetProgressBar_new);
     $em->flush();
     return $this->redirectToRoute('gadgetprogressbar_edit', ['id' => $gadgetProgressBar_new->getId()]);
 }
Example #2
0
 /**
  * Remove gadgetsProgressBar
  *
  * @param \VisualizationBundle\Entity\GadgetProgressBar $gadgetsProgressBar
  */
 public function removeGadgetsProgressBar(\VisualizationBundle\Entity\GadgetProgressBar $gadgetsProgressBar)
 {
     $this->gadgets_progress_bar->removeElement($gadgetsProgressBar);
 }