protected function cloneWidgetMap(WidgetMap $widgetMap, View $view)
    {
        $originalWidgetMap = $widgetMap;
        $widgetMap = clone $widgetMap;
        $widgetMap->setId(null);
        $widgetMap->setAction(WidgetMap::ACTION_OVERWRITE);
        $widgetMap->setReplaced($originalWidgetMap);
        $widgetMap->setView($view);
        $view->addWidgetMap($widgetMap);
        $this->em->persist($widgetMap);

        return $widgetMap;
    }