Property | Type | Description | |
---|---|---|---|
$actsAs | array | Behaviors used by the Model | |
$findMethods | |||
$hasAndBelongsToMany | array | Model associations: hasAndBelongsToMany | |
$name | string | Model name | |
$validate | array | Validation |
Method | Description | |
---|---|---|
add ( $data, $vocabularyId ) : array | boolean | Save term | |
beforeDelete ( $cascade = true ) : boolean | Allow delete on whether given Term has any association left with Taxonomy | |
edit ( $data, $vocabularyId ) : array | boolean | Edit term | |
hasSlugChanged ( integer $id, string $slug ) : boolean | Checks wether slug has changed for given Term id | |
isInVocabulary ( integer $id, integer $vocabularyId, integer $taxonomyId = null ) : boolean | Convenience method to check whether term exists within a vocabulary | |
remove ( integer $id, integer $vocabularyId ) | Remove term | |
saveAndGetId ( array $data ) : integer | Save Term and return ID. | |
setScopeForTaxonomy ( integer $vocabularyId ) | Set Scope | |
slugExists ( $slug ) : boolean | Convenience check for slug |
Method | Description | |
---|---|---|
_findByVocabulary ( $state, $query, $results = [] ) | ||
_save ( array $data, integer $vocabularyId, integer $taxonomyId = null ) | Save new/updated term data |
public beforeDelete ( $cascade = true ) : boolean | ||
return | boolean |
public saveAndGetId ( array $data ) : integer | ||
$data | array | |
return | integer |
public setScopeForTaxonomy ( integer $vocabularyId ) | ||
$vocabularyId | integer | Vocabulary Id |
public slugExists ( $slug ) : boolean | ||
return | boolean |
public array $hasAndBelongsToMany | ||
return | array |