protected function analyzeForTranslatable()
    {
        /** @var Model|Translatable $model */
        $model = $this->model;

        $translationModel = $model->getTranslationModelName();

        $this->info = $this->analyzer->analyze($translationModel);

        $attributes = $this->info['attributes'];

        foreach ($attributes as $key => $attribute) {
            if ( ! $model->isTranslationAttribute($key)) continue;

            // mark the fields as translated for merging by model analyzer
            $attributes[$key]['translated'] = true;
        }

        $this->info['attributes'] = $attributes;
    }
protected function analyzeForTranslatable()
    {
        /** @var Model|Translatable $model */
        $model = $this->model;

        $translationModel = $model->getTranslationModelName();

        $this->info = $this->analyzer->analyze($translationModel);

        $attributes = $this->info['attributes'];

        foreach ($attributes as $key => $attribute) {
            if ( ! $model->isTranslationAttribute($key)) continue;

            // mark the fields as translated for merging by model analyzer
            $attributes[$key]['translated'] = true;
        }

        $this->info['attributes'] = $attributes;
    }
protected function analyzeForTranslatable ( ) { /** @var Model|Translatable $model */ $ model = $ this -> model ; $ translationModel = $ model -> getTranslationModelName ( ) ; $ this -> info = $ this -> analyzer -> analyze ( $ translationModel ) ; $ attributes = $ this -> info [ 'attributes' ] ; foreach ( $ attributes as $ key => $ attribute ) { if ( ! $ model -> isTranslationAttribute ( $ key ) ) continue ; // mark the fields as translated for merging by model analyzer $ attributes [ $ key ] [ 'translated' ] = true ; } $ this -> info [ 'attributes' ] = $ attributes ; }
Analyzes a model using the translatable trait strategy.
Analyzes a model using the translatable trait strategy .