this issue is somewhat related to: #1829636: "All languages" suffix not working nicely with multi-value fields

I do admit i have never understood the name of this module being Entity Translation when i think it is specifically NOT entity translation; but field translation. That being said there do seem to be bits of code through out this module which deal with entities (when i think they should be dealing with fields).

I am working on supporting ET (ughh.. Field Translation) for the Paragraphs module and the issues i am coming across is that ET does things based on the parent "field/entity" rather than on the child "field". One example of this the function: entity_translation_element_translatability_clue() which deals with adding the (all languages) suffix to the fields title. That function decides to append based on the #multilingual setting of a field (parent, which in Paragraphs case is an entity) and then calls the function: _entity_translation_element_title_append() which attempts to determine if there are child elements (fields) and adds the suffix to these.

The issue with this is that it is no longer field based. The 2nd function which determines children does not evaluate the children on whether or not they are translatable. This is left to the 1st function which only checks the parent.

The recursing into the children part of this is sound; but the checking for translatability is lost.

This approach seems to show in other functions as well although i have been able to circumvent what ET and core are doing with hooks that are in place. For example, when i go to save a field value (which is in my paragraph, which is within my node), the language of the field is set to that of the parent (und), not of the child field which is set as translatable.

Not sure i completely understand all of this but certainly seems as though the underlying concept of how ET works is flawed as it is not dealing with child fields. But maybe i missed something and this really isn't "field translation".

Comments

liquidcms created an issue.