Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Hi,
I have several translations (Japan, French, English) for one node using translatable fields. Source language is Japan. When clicking the edition link (node/XX/edit), the English translatable fields appear.
If I only have French and Japan translations, the French translatable fields appear.
It doesn't seem very logical. By default, it should be the translatable fields from source language (Japan).
Currently, if no language code is found in node edition URL, entity_translation_form_language()
function is called and apply these rules:
- Get
$GLOBALS['language_content']->language
translation (English in my case) - Otherwise, get the first existing translation found for this content
Comment | File | Size | Author |
---|---|---|---|
#2 | entity_translation-default_langcode_for_edit_page-2173445-2.patch | 900 bytes | make77 |
#1 | entity_translation-default_langcode_for_edit_page-2173445-1.patch | 604 bytes | make77 |
Comments
Comment #1
make77 CreditAttribution: make77 commentedComment #2
make77 CreditAttribution: make77 commentedI updated patch for latest version of entity_translation.
I also moved this correction directly into
entity_translation_get_existing_language
function.