Свойство | Type | Description | |
---|---|---|---|
$translatableViewBag | Data store for translated viewbag attributes. |
Méthode | Description | |
---|---|---|
__construct ( October\Rain\Database\Model $model ) | Constructor | |
getTranslatableModelClass ( ) : array | Returns a collection of fields that will be hashed. | |
syncTranslatableAttributes ( ) | {@inheritDoc} |
Méthode | Description | |
---|---|---|
createModel ( ) : Model | Internal method, prepare the form model object | |
getCmsObjectForLocale ( $locale ) | ||
isEmptyDataSet ( array $data ) : boolean | Returns true if all attributes are empty (false when converted to booleans). | |
loadTranslatableData ( string $locale = null ) : array | Loads the translation data from the join table. | |
mergeViewBagAttributes ( ) : void | Merge the viewBag array for the base and translated objects. | |
overrideTwigCacheKey ( $key ) : string | null | Translated CMS objects need their own unique cache key in twig. | |
storeTranslatableData ( string $locale = null ) : void | Saves the translation data in the join table. | |
syncTranslatableFileNames ( ) | If the parent model file name is changed, this should be reflected in the translated models also. |
public __construct ( October\Rain\Database\Model $model ) | ||
$model | October\Rain\Database\Model | The extended model. |
protected createModel ( ) : Model | ||
Résultat | Model |
public getTranslatableModelClass ( ) : array | ||
Résultat | array |
protected isEmptyDataSet ( array $data ) : boolean | ||
$data | array | |
Résultat | boolean |
protected loadTranslatableData ( string $locale = null ) : array | ||
$locale | string | |
Résultat | array |
protected mergeViewBagAttributes ( ) : void | ||
Résultat | void |
protected overrideTwigCacheKey ( $key ) : string | null | ||
Résultat | string | null |
protected storeTranslatableData ( string $locale = null ) : void | ||
$locale | string | |
Résultat | void |
protected syncTranslatableFileNames ( ) |