Bundle/WidgetMapBundle/Entity/Slot.php
public function getWidgetMapByWidgetId($widgetId)
    {
        $widgetMap = null;

        $widgetMaps = $this->widgetMaps;

        //parse the widgets maps
        foreach ($widgetMaps as $wm) {
            if ($wm->getWidgetId() === $widgetId) {
                $widgetMap = $wm;
                //entity found, there is no need to continue
                break;
            }
        }

        return $widgetMap;
    }
public function getWidgetMapByWidgetId($widgetId)
    {
        $widgetMap = null;

        $widgetMaps = $this->widgetMaps;

        //parse the widgets maps
        foreach ($widgetMaps as $wm) {
            if ($wm->getWidgetId() === $widgetId) {
                $widgetMap = $wm;
                //entity found, there is no need to continue
                break;
            }
        }

        return $widgetMap;
    }
public function getWidgetMapByWidgetId ( $ widgetId ) { $ widgetMap = null ; $ widgetMaps = $ this -> widgetMaps ; //parse the widgets maps foreach ( $ widgetMaps as $ wm ) { if ( $ wm -> getWidgetId ( ) === $ widgetId ) { $ widgetMap = $ wm ; //entity found, there is no need to continue break ; } } return $ widgetMap ; }
Get the widget map by the widget id.

@param int $widgetId

@return WidgetMap
Get the widget map by the widget id .