Méthode | Description | |
---|---|---|
__isset ( $key ) : boolean | ||
deleteTranslations ( string | array | null $locales = null ) | Deletes all translations for this model. | |
fill ( array $attributes ) | ||
getAttribute ( string $key ) : mixed | ||
getLocaleKey ( ) : string | ||
getNewTranslation ( string $locale ) : |
||
getRelationKey ( ) : string | ||
getTranslation ( string | null $locale = null, boolean $withFallback = null ) : |
||
getTranslationModelName ( ) : string | ||
getTranslationModelNameDefault ( ) : string | ||
hasTranslation ( string | null $locale = null ) : boolean | ||
isTranslationAttribute ( string $key ) : boolean | ||
save ( array $options = [] ) : boolean | ||
scopeListsTranslations ( |
Adds scope to get a list of translated attributes, using the current locale. | |
scopeNotTranslatedIn ( |
||
scopeTranslated ( |
||
scopeTranslatedIn ( |
||
scopeWhereTranslation ( |
This scope filters results by checking the translation fields. | |
scopeWhereTranslationLike ( |
This scope filters results by checking the translation fields. | |
scopeWithTranslation ( |
This scope eager loads the translations for the default and the fallback locale only. | |
setAttribute ( string $key, mixed $value ) | ||
toArray ( ) : array | ||
translate ( string | null $locale = null, boolean $withFallback = false ) : |
Alias for getTranslation(). | |
translateOrDefault ( string $locale ) : |
Alias for getTranslation(). | |
translateOrNew ( string $locale ) : |
Alias for getTranslationOrNew(). | |
translations ( ) : Illuminate\Database\Eloquent\Relations\HasMany |
Méthode | Description | |
---|---|---|
getLocaleSeparator ( ) : string | ||
getLocales ( ) : array | ||
getTranslationOrNew ( string $locale ) : |
||
isKeyALocale ( string $key ) : boolean | ||
isTranslationDirty ( |
||
locale ( ) : string | ||
saveTranslations ( ) : boolean |
Méthode | Description | |
---|---|---|
alwaysFillable ( ) : boolean | ||
getFallbackLocale ( null $locale = null ) : string | ||
getLanguageFromCountryBasedLocale ( $locale ) : string | ||
getTranslationByLocaleKey ( string $key ) | ||
getTranslationsTable ( ) : string | ||
isLocaleCountryBased ( $locale ) : boolean | ||
useFallback ( ) : boolean | null |
public getAttribute ( string $key ) : mixed | ||
$key | string | |
Résultat | mixed |
public getNewTranslation ( string $locale ) : |
||
$locale | string | |
Résultat |
public getTranslationModelName ( ) : string | ||
Résultat | string |
public getTranslationModelNameDefault ( ) : string | ||
Résultat | string |
protected getTranslationOrNew ( string $locale ) : |
||
$locale | string | |
Résultat |
protected isKeyALocale ( string $key ) : boolean | ||
$key | string | |
Résultat | boolean |
public isTranslationAttribute ( string $key ) : boolean | ||
$key | string | |
Résultat | boolean |
protected isTranslationDirty ( |
||
$translation | ||
Résultat | boolean |
public scopeListsTranslations ( |
||
$query | ||
$translationField | string |
public scopeNotTranslatedIn ( |
||
$query | ||
$locale | string | |
Résultat |
public scopeTranslated ( |
||
$query | ||
Résultat |
public scopeTranslatedIn ( |
||
$query | ||
$locale | string | |
Résultat |
public scopeWithTranslation ( |
||
$query |
public setAttribute ( string $key, mixed $value ) | ||
$key | string | |
$value | mixed |
public translateOrDefault ( string $locale ) : |
||
$locale | string | |
Résultat |
public translateOrNew ( string $locale ) : |
||
$locale | string | |
Résultat |
public translations ( ) : Illuminate\Database\Eloquent\Relations\HasMany | ||
Résultat | Illuminate\Database\Eloquent\Relations\HasMany |