Ejemplo n.º 1
0
 /**
  * {@inheritdoc}
  */
 protected function findEntity($value)
 {
     if ($term_id = parent::findEntity($value)) {
         return $term_id;
     }
     $term = $this->termStorage->create(array('vid' => 'tags', 'name' => $value));
     $term->save();
     return $term->id();
 }
Ejemplo n.º 2
0
 /**
  * {@inheritdoc}
  */
 protected function newEntity(FeedInterface $feed)
 {
     $values = $this->configuration['values'];
     $values = $this->apply('newEntityValues', $feed, $values);
     return $this->storageController->create($values);
 }