public function getTermsByVocabularyName($name) {
    $vocabulary = \Taxonomy::getVocabularyByName($name);

    return $this->related()->where('vocabulary_id', $vocabulary->id)->get();
  }
public function getTermsByVocabularyName($name) {
    $vocabulary = \Taxonomy::getVocabularyByName($name);

    return $this->related()->where('vocabulary_id', $vocabulary->id)->get();
  }
public function getTermsByVocabularyName ( $ name ) { $ vocabulary = \ Taxonomy :: getVocabularyByName ( $ name ) ; return $ this -> related ( ) -> where ( 'vocabulary_id' , $ vocabulary -> id ) -> get ( ) ; }
Get all the terms for a given vocabulary that are linked to the current
Model.

@param $name string
The name of the vocabulary

@return object
A collection of TermRelation objects
Get all the terms for a given vocabulary that are linked to the current Model .