Example #1
0
 /**
  * Create a new feature entry
  *
  * @param FeatureAvCreateEvent $event
  * @param $eventName
  * @param EventDispatcherInterface $dispatcher
  */
 public function create(FeatureAvCreateEvent $event, $eventName, EventDispatcherInterface $dispatcher)
 {
     $feature = new FeatureAvModel();
     $feature->setDispatcher($dispatcher)->setFeatureId($event->getFeatureId())->setLocale($event->getLocale())->setTitle($event->getTitle())->save();
     $event->setFeatureAv($feature);
 }
Example #2
0
 /**
  * Create a new feature entry
  *
  * @param FeatureAvCreateEvent $event
  */
 public function create(FeatureAvCreateEvent $event)
 {
     $feature = new FeatureAvModel();
     $feature->setDispatcher($event->getDispatcher())->setFeatureId($event->getFeatureId())->setLocale($event->getLocale())->setTitle($event->getTitle())->save();
     $event->setFeatureAv($feature);
 }