Allow a WebformEmailHandler to specify the language of an email message.

Created on 9 April 2024, 9 months ago

Problem/Motivation

Many sites will translate a webform, but the email recipients only speak the default language.

Email recipients are okay get the submitted values in the submitters chosen language but they would like the email's element labels, options, and text to not be translated.

Steps to reproduce

Proposed resolution

Allow a WebformEmailHandler to specify the language of an email message.

Remaining tasks

  • Create a POC with some test coverage
  • Review the MR and refine it.
  • Commit the MR.

User interface changes

New language option under the advanced settings for the webform email handler.

API changes

Hopefully, none, and we will switch the email's language when the advanced settings are selected.

Data model changes

None.

Feature request
Status

Active

Version

6.2

Component

Code

Created by

🇺🇸United States jrockowitz Brooklyn, NY

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

  • Pipeline finished with Failed
    9 months ago
    Total: 443s
    #136777
  • Pipeline finished with Failed
    9 months ago
    Total: 392s
    #136785
  • Pipeline finished with Failed
    9 months ago
    Total: 388s
    #136820
  • Issue created by @jrockowitz
  • Open in Jenkins → Open on Drupal.org →
    Core: 10.1.4 + Environment: PHP 8.2 & MySQL 8
    last update 9 months ago
    533 pass, 2 fail
  • Pipeline finished with Failed
    9 months ago
    Total: 1899s
    #141770
  • Open in Jenkins → Open on Drupal.org →
    Core: 10.1.4 + Environment: PHP 8.2 & MySQL 8
    last update 9 months ago
    533 pass, 2 fail
  • Pipeline finished with Failed
    9 months ago
    Total: 1997s
    #141826
  • Open in Jenkins → Open on Drupal.org →
    Core: 10.1.4 + Environment: PHP 8.2 & MySQL 8
    last update 9 months ago
    533 pass, 2 fail
  • Pipeline finished with Failed
    9 months ago
    Total: 2087s
    #142640
  • Open in Jenkins → Open on Drupal.org →
    Core: 10.1.4 + Environment: PHP 8.2 & MySQL 8
    last update 9 months ago
    533 pass, 2 fail
  • Open in Jenkins → Open on Drupal.org →
    Core: 10.1.4 + Environment: PHP 8.2 & MySQL 8
    last update 9 months ago
    533 pass, 2 fail
  • Pipeline finished with Canceled
    9 months ago
    Total: 1322s
    #142838
  • Pipeline finished with Failed
    9 months ago
    Total: 2283s
    #142867
  • Open in Jenkins → Open on Drupal.org →
    Core: 10.1.4 + Environment: PHP 8.2 & MySQL 8
    last update 9 months ago
    537 pass
  • Pipeline finished with Success
    9 months ago
    Total: 2374s
    #142933
  • 🇺🇸United States jrockowitz Brooklyn, NY
  • Status changed to Needs review 9 months ago
  • Open in Jenkins → Open on Drupal.org →
    Core: 10.1.4 + Environment: PHP 8.2 & MySQL 8
    last update 9 months ago
    537 pass
  • 🇺🇸United States jrockowitz Brooklyn, NY
  • Open in Jenkins → Open on Drupal.org →
    Core: 10.1.4 + Environment: PHP 8.2 & MySQL 8
    last update 8 months ago
    534 pass
  • Open in Jenkins → Open on Drupal.org →
    Core: 10.1.4 + Environment: PHP 8.2 & MySQL 8
    last update 8 months ago
    534 pass
  • 🇺🇸United States jrockowitz Brooklyn, NY
  • Pipeline finished with Success
    8 months ago
    Total: 2372s
    #150153
  • Open in Jenkins → Open on Drupal.org →
    Core: 10.1.4 + Environment: PHP 8.2 & MySQL 8
    last update 8 months ago
    537 pass
  • Open in Jenkins → Open on Drupal.org →
    Core: 10.1.4 + Environment: PHP 8.2 & MySQL 8
    last update 8 months ago
    537 pass
  • 🇺🇸United States jrockowitz Brooklyn, NY
  • Pipeline finished with Success
    8 months ago
    Total: 2358s
    #150215
  • 🇧🇪Belgium arno_vgh Antwerp

    This functionality appears to be functioning correctly based on my testing.
    Here are the steps I followed:

    • Created a simple webform with some elements and ensured they were translated.
    • Added email handlers for the 'current', 'Dutch' (which is my current language), and 'English' versions.
    • Submitted Webform.
    • I observed that emails were sent appropriately, with the 'Dutch' and 'current' versions using the Dutch translation, while the 'English' version used the English translation. 😊
  • 🇺🇸United States jrockowitz Brooklyn, NY

    Thanks for the review. This was a very tricky request from a client. I am hesitant to merging it until a few people need it and use it.

  • Pipeline finished with Failed
    8 months ago
    Total: 386s
    #161652
  • Pipeline finished with Failed
    8 months ago
    Total: 539s
    #161710
  • Pipeline finished with Failed
    8 months ago
    Total: 378s
    #161738
  • Pipeline finished with Success
    8 months ago
    Total: 528s
    #161743
  • Pipeline finished with Success
    8 months ago
    Total: 379s
    #162585
  • 🇧🇪Belgium matthiaso Leuven

    Tested on a simple webform and works as expected. Thanks!

    We'll test this in the following days on a client's complex conditional and multistep webform.

  • Pipeline finished with Success
    6 months ago
    Total: 211s
    #219685
  • Pipeline finished with Success
    6 months ago
    Total: 212s
    #219686
  • Pipeline finished with Success
    5 months ago
    Total: 216s
    #222973
  • 🇺🇸United States jrockowitz Brooklyn, NY
  • 🇺🇸United States jrockowitz Brooklyn, NY

    I am open to merging this AS-IS because the enhancement needs to be enabled.

  • Toy poodle fiyat, köpek sahiplenme düşünenlerin en merak ettiği konulardan biridir. Bu fiyatlar, rengine, boyutuna (mini, toy, standart) ve poodle fiyatcinsiyetine (dişi, erkek) göre değişiklik gösterir. toy poodle fiyatları ortalama olarak toy poodle fiyat skalası 12000 TL ile 25000 TL arası toy poodle fiyat ortalaması değişiklik göstermektedir.

    Toy Poodle fiyatları birkaç farklı faktöre bağlı olarak değişiklik göstermektedir:

    Ortalama Toy Poodle Fiyat Aralığı:

    Genel olarak, Toy Poodle yavru fiyat skalası 12.000 TL ile 40.000 TL arasında değişmektedir.

    Fiyatları Etkileyen Faktörler:

    Soy ve Şecere: Şampiyon soylu veya safkan bir Toy Poodle yavrusu, daha yüksek bir fiyata sahip olacaktır.

    Renk: Bazı renkler, özellikle kırmızı ve kırmızı kahverengi, daha nadir ve popüler olduğu için daha pahalı olabilir.

    Cinsiyet: Bazı durumlarda, dişi yavrular erkek yavrulardan biraz daha pahalı olabilir.

    Üretici: Yetiştiriciler, pet shoplara göre genellikle daha uygun fiyatlar talep ederler, ancak yavruların sağlıklı ve iyi bakılmış olmaları daha olasıdır.

    Coğrafi Konum: Farklı şehirlerde veya bölgelerde fiyatlar değişiklik gösterebilir.

  • 🇭🇺Hungary mxr576 Hungary
    +    langcode:
    +      type: string
    +      label: Language
    

    Do we need to update existing plugin instances in an update hook due to this config schema change? Will the stored config schema remain valid?

  • 🇺🇸United States jrockowitz Brooklyn, NY

    Yeh, we should add an update hook.

Production build 0.71.5 2024